Skip to content

Conversation

@harry671003
Copy link
Contributor

@harry671003 harry671003 commented Aug 7, 2024

  • I added CHANGELOG entry for this change.
  • Change is not relevant to the end user.

Changes

Prometheus recently introduced limit param in metadata APIs to allow users to opt for a limited number of results.

This PR implements the limit param in Thanos API.

Verification

  • Updated the unit tests to cover the case of when limit is passed.

Related

Signed-off-by: 🌲 Harry 🌊 John 🏔 <[email protected]>
@harry671003 harry671003 force-pushed the implement_limit_in_api branch from 384aff2 to a211347 Compare August 7, 2024 19:15
@harry671003 harry671003 changed the title Metadata API: Add limit param API: Implement limit param in metadata APIs Aug 7, 2024
@harry671003 harry671003 changed the title API: Implement limit param in metadata APIs API: Add limit param in metadata APIs Aug 7, 2024
@harry671003 harry671003 marked this pull request as ready for review August 7, 2024 19:44
saswatamcode
saswatamcode previously approved these changes Aug 8, 2024
Copy link
Member

@saswatamcode saswatamcode left a comment

Choose a reason for hiding this comment

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

Thanks! Just one small question

Signed-off-by: 🌲 Harry 🌊 John 🏔 <[email protected]>
Copy link
Contributor

@yeya24 yeya24 left a comment

Choose a reason for hiding this comment

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

Thanks. Great work

* [#7592](https://github.com/thanos-io/thanos/pull/7592) Ruler: Only increment `thanos_rule_evaluation_with_warnings_total` metric for non PromQL warnings.

### Added
* [7609](https://github.com/thanos-io/thanos/pull/7609) API: Add limit param to metadata APIs (series, label names, label values).
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we can omit the changelog here and add in the actual store implementation PR.
But not a big deal. We can update the changelog when you create another PR

Copy link
Contributor

Choose a reason for hiding this comment

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

This missed #. We can fix in your next pr

@yeya24 yeya24 merged commit a3a7c3b into thanos-io:main Aug 8, 2024
jnyi pushed a commit to jnyi/thanos that referenced this pull request Oct 17, 2024
fpetkovski pushed a commit to fpetkovski/thanos that referenced this pull request Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants