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

Make max search limit configurable #1044

Merged
merged 3 commits into from
Oct 15, 2021
Merged

Conversation

yvrhdn
Copy link
Member

@yvrhdn yvrhdn commented Oct 15, 2021

What this PR does:
Adds a new configuration parameter to the querier search_max_result_limit which allows you to set a server-side max limit. I.e. if a user sends a query with limit=10000 but search_max_result_limit=100 we will only search for 100 traces.

I've also added some long overdue test cases for the query parsing. I've deliberately not changed the existing code.

Which issue(s) this PR fixes:
Fixes #

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

Copy link
Member

@mapno mapno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall, just left a comment

modules/querier/querier_search_test.go Show resolved Hide resolved
@yvrhdn yvrhdn merged commit 29e9129 into grafana:main Oct 15, 2021
@yvrhdn yvrhdn deleted the search-max-limit branch October 15, 2021 15:55
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.

4 participants