[ https://issues.apache.org/jira/browse/SOLR-8621?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15123372#comment-15123372 ]
Christine Poerschke commented on SOLR-8621: ------------------------------------------- proposed in SOLR-5730: bq. ... out-of-the-box factories for all existing non-wrapping merge policies e.g. {code} <!-- public TieredMergePolicy() { --> <mergePolicyFactory class="TieredMergePolicyFactory"> <int name="segmentsPerTier">42</int> </mergePolicyFactory> {code} bq. An out-of-the-box factory ... for existing plain wrapping merge policies e.g. {code} <!-- public UpgradeIndexMergePolicy(MergePolicy base) { --> <mergePolicyFactory class="UpgradeIndexMergePolicyFactory"> <str name="base">TieredMergePolicyFactory</str> <int name="base.segmentsPerTier">42</int> </mergePolicyFactory> {code} bq. The factory for building sorting merge policies \[in SOLR-5730\] could look something like this: {code} <!-- public SortingMergePolicy(MergePolicy in, Sort sort) { --> <mergePolicyFactory class="SortingMergePolicyFactory"> <str name="in">TieredMergePolicyFactory</str> <int name="in.segmentsPerTier">42</int> <str name="sort">timestamp desc</str> </mergePolicyFactory> {code} bq. For consistency ... conceptually support wrapping of wrapping merge policies e.g. someone could go and create their own MyInstrumentedMergePolicyFactory factory and use it like this: {code} <!-- public MyInstrumentedMergePolicy(MergePolicy mergePolicy) { --> <mergePolicyFactory class="MyInstrumentedMergePolicyFactory"> <str name="mergePolicy">SortingMergePolicyFactory</str> <str name="mergePolicy.in">TieredMergePolicyFactory</str> <int name="mergePolicy.in.segmentsPerTier">42</int> <str name="mergePolicy.sort">timestamp desc</str> <int name="instrumentationLevel">42</int> </mergePolicyFactory> {code} > solrconfig.xml: deprecate/replace <mergePolicy> with <mergePolicyFactory> > ------------------------------------------------------------------------- > > Key: SOLR-8621 > URL: https://issues.apache.org/jira/browse/SOLR-8621 > Project: Solr > Issue Type: Task > Reporter: Christine Poerschke > Assignee: Christine Poerschke > > *<mergePolicyFactory> end-user benefits:* > * Lucene's UpgradeIndexMergePolicy can be configured in Solr > * (with SOLR-5730) Lucene's SortingMergePolicy can be configured in Solr > * customisability: arbitrary merge policies including wrapping/nested merge > policies can be created and configured > *roadmap:* > * solr 5.5 introduces <mergePolicyFactory> support > * solr 5.5(\?) deprecates (but maintains) <mergePolicy> support > * solr 6.0(\?) removes <mergePolicy> support > *ticket todos* > * add <mergePolicyFactory> examples to this ticket > * work-in-progress git branch off master - to be created (Christine) > * Solr Reference Guide update (at/towards the very end i.e. master and > branch_5x commits) -- 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