Repository navigation
[2.0] fix: guard ranking script_score against zero-match segments (Lucene 10 NPE) - #33317
Conversation
…0 NPE) (#33292) On Lucene 10 (OpenSearch 3.x), a script_score whose inner query matches zero documents on a segment returns a null sub-scorer, which DisjunctionMaxScorer/DisiWrapper rejects with a NullPointerException. Wrapped in dis_max with allow_partial_search_results=true, the failing shard is silently dropped and search returns 0 results even though the matching document exists (#33167). Wrap the inner query in a single-clause bool[should, minimumShouldMatch=1] so a zero-match segment yields a well-defined empty iterator instead of null. Scoring is unchanged: a single-clause bool with no must/filter scores exactly its clause. Co-authored-by: Sriharsha Chintalapani <[email protected]> (cherry picked from commit 38cbdf9)
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
✅ Playwright Results — workflow succeededValidated commit ✅ 618 passed · ❌ 0 failed · 🟡 1 flaky · ⏭️ 0 skipped · 🧰 0 lifecycle flaky PerformanceBlocking targets: ✅ met · Optimization targets: 🟡 in progress Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting. 🕒 Full workflow signal wall (to summary) 49m 47s ⏱️ Max setup 3m 50s · max shard execution 13m 52s · max shard-job elapsed before upload 17m 41s · reporting 5s 🌐 173.00 requests/attempt · 1.55 app boots/UI scenario · 10.70% common-shard skew Optimization targets still in progress:
🟡 1 flaky test(s) (passed on retry)
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
Automated backport of #33292 to
2.0.38cbdf9f7878bda711e7f763b0261c3fca46ef08main.Opened from openmetadata-collate, which holds the credentials needed to open a PR here. It merges itself once every check passes — no review needed. If a check fails it stays open and the author of #33292 is asked to look.
resolver run