Avoid exhaustive score mode in QueryPhaseCollector - #155690
Conversation
|
Pinging @elastic/es-search-foundations (Team:Search Foundations) |
|
Hi @reugn, I've created a changelog YAML for you. |
🔍 Preview links for changed docs⏳ Building and deploying preview... View progress This comment will be updated with preview links when the build is complete. |
ℹ️ Important: Docs version tagging👋 Thanks for updating the docs! Just a friendly reminder that our docs are now cumulative. This means all 9.x versions are documented on the same page and published off of the main branch, instead of creating separate pages for each minor version. We use applies_to tags to mark version-specific features and changes. Expand for a quick overviewWhen to use applies_to tags:✅ At the page level to indicate which products/deployments the content applies to (mandatory) What NOT to do:❌ Don't remove or replace information that applies to an older version 🤔 Need help?
|
Addresses the two TODOs in
QueryPhaseCollector.scoreMode:TOP_DOCS_WITH_SCORESinstead ofCOMPLETE. Aggs do report these score modes, seeCompositeAggregatorandGlobalOrdCardinalityAggregator.min_score,TOP_DOCSnow becomesTOP_DOCS_WITH_SCORESandTOP_DOCS_WITH_SCORESis left alone, instead of both becomingCOMPLETE.In both cases we get the scores we need without asking for exhaustive collection. The rest of the behaviour is unchanged:
COMPLETE_NO_SCORESwithmin_scorestill becomesCOMPLETE, skipping is still up to the collectors, andsetMinCompetitiveScoreis still ignored when aggs are collected.Adds two tests that run real searches with real collectors, one per case.
Closes #97271