[ 
https://issues.apache.org/jira/browse/SOLR-5730?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15110679#comment-15110679
 ] 

Christine Poerschke commented on SOLR-5730:
-------------------------------------------

bq. ... i'm not really a fan of the 2 new disjoint top level config options ...

I agree that having a {{<useSortingMergePolicy>true</useSortingMergePolicy>}} 
element in solrconfig.xml and a {{<mergeSortSpec>timestamp 
desc</mergeSortSpec>}} element in schema.xml is tricky but personally am not 
won over by either of the obvious two alternatives either:

*Alternative #1 solrconfig.xml element only:*
+ advantage: the element is co-located with the existing <mergePolicy> element
\- disadvantages:
* solrconfig.xml references schema.xml field names
* solr.search.SolrIndexSearcher would need (more) access to the 
solr.update.SolrIndexConfig object \[implementation detail: 
SolrIndexSearcher.buildAndRunCollectorChain needs to be able to pass the merge 
policy sort to EarlyTerminatingSortingCollector but only one of the two 
SolrIndexSearcher constructors currently takes an SolrIndexConfig argument.\]

*Alternative #2 schema.xml element only:*
+ advantage: the element uses solr field names defined in the same file
\- disadvantage: the presence or absence of an element in schema.xml has a side 
effect on how the solrconfig.xml <mergePolicy> element is instantiated

*Alternative #3 perhaps there is another way?*

> make Lucene's SortingMergePolicy and EarlyTerminatingSortingCollector 
> configurable in Solr
> ------------------------------------------------------------------------------------------
>
>                 Key: SOLR-5730
>                 URL: https://issues.apache.org/jira/browse/SOLR-5730
>             Project: Solr
>          Issue Type: New Feature
>            Reporter: Christine Poerschke
>            Assignee: Christine Poerschke
>            Priority: Minor
>         Attachments: SOLR-5730-part1of2.patch, SOLR-5730-part2of2.patch
>
>
> *Example configuration (SortingMergePolicy):*
> solrconfig.xml
> {noformat}
> <useSortingMergePolicy>true</useSortingMergePolicy>
> {noformat}
> schema.xml
> {noformat}
> <mergeSortSpec>timestamp desc</mergeSortSpec>
> {noformat}
> *Example use (EarlyTerminatingSortingCollector):*
> {noformat}
> &sort=timestamp+desc&segmentTerminateEarly=true
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to