Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Control search index's text match scope through (local) latencies. #8674

Merged
merged 6 commits into from
Mar 28, 2025

Conversation

isoos
Copy link
Collaborator

@isoos isoos commented Mar 26, 2025

  • Controls both package index (Package search index improvements (tracking issue) #8671) and SDK index (SDK search index improvements (tracking issue) #8670).
  • While the changes inside the text search seems a lot, it is mostly the indent change, otherwise only skipping the index matches when the textMatchExtent field does not support it.
  • Returns an errorMessage when not even the name index was used. (TBD: more noticeable exposure of such messages)
  • Introduces latency tracking with half-life decay of one minute. Considered alternatives: aggregation over last-N-events, last-X-minute, sampling over Y-minutes window.
  • This is scoped only at the local index level. To make this consistent across all search instances, we could synchronize such decaying value(s) through redis. TBD in a subsequent PR.
  • Note: I've also considered enum or bools for controlling the match extent, but that was more complex without much gain.

@isoos isoos requested review from jonasfj and sigurdm March 26, 2025 16:36
@isoos isoos force-pushed the text-search-extent branch from 44a5993 to 4022eb2 Compare March 26, 2025 16:41
@isoos isoos force-pushed the text-search-extent branch from 4022eb2 to e0bbf3a Compare March 27, 2025 10:40
@isoos isoos merged commit efc6215 into dart-lang:master Mar 28, 2025
31 checks passed
@isoos isoos deleted the text-search-extent branch March 28, 2025 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants