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

ASF subversion and git services commented on SOLR-18099:
--------------------------------------------------------

Commit a77b42f784f85f0de7deb6fc0a0b0b889d82ecc4 in solr's branch 
refs/heads/main from David Smiley
[ https://gitbox.apache.org/repos/asf?p=solr.git;h=a77b42f784f ]

SOLR-18099: CollapseQParser extensibility (#4112)

- `CollapsingQParserPlugin.java` — large refactor consolidating the many 
near-duplicate collector classes onto a shared `AbstractCollapseCollector` 
template-method base and converting `GroupHeadSelectorType` to a record; also 
swaps the collapsed-doc accumulator from `FixedBitSet` to `DocIdSetBuilder` to 
save memory on sparse result sets (benchmarked with no measurable speed 
regression). Net effect: ~575 fewer lines while opening up extension points for 
custom group-head selection.
- 
`{IntFloatDynamicMap.java,IntIntDynamicMap.java,IntLongDynamicMap.java,DynamicMap.java}`
 — add a tracked `size()` so the refactored collectors can size 
`DocIdSetBuilder` growth calls.
- `BitDocSet.java` — widen `makeQuery()`'s return type to `Query` to support 
subclassing.
- `{TestCollapseQParserPlugin.java,TestRandomCollapseQParserPlugin.java}` — 
updated for the refactored collector APIs.
- `collapse-and-expand-results.adoc` — doc touch-ups reflecting the refactor.

> CollapsingQParserPlugin extensibility
> -------------------------------------
>
>                 Key: SOLR-18099
>                 URL: https://issues.apache.org/jira/browse/SOLR-18099
>             Project: Solr
>          Issue Type: Improvement
>          Components: query parsers
>            Reporter: David Smiley
>            Assignee: David Smiley
>            Priority: Minor
>              Labels: pull-request-available
>          Time Spent: 1h 20m
>  Remaining Estimate: 0h
>
> I wish to make CollapsingQParserPlugin more extensible.  Where I work, we've 
> got a forked version that subclasses the internal OrdFieldValueStrategy (a 
> Collector) class. Mostly, make some classes/method/fields protected but not 
> even a lot.  The internal enum 
> com.bloomberg.blaw.search.solr.qparser.CollapsingQParserPlugin.GroupHeadSelectorType
>  needs a CUSTOM variant that a subclass can parse as it needs to.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to