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

[optimization] cache prometheus : fix "loki_cache_request_duration_seconds_bucket" ‘status_code’ label always equals "200" #4891

Merged
merged 11 commits into from
Jan 14, 2022

Conversation

liguozhong
Copy link
Contributor

refer issue :#4862
alert promql.
image

image

image

…conds_bucket" ‘status_code’ label always equals "200"
@liguozhong liguozhong requested a review from a team as a code owner December 8, 2021 09:16
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
@stale
Copy link

stale bot commented Jan 8, 2022

Hi! This issue has been automatically marked as stale because it has not had any
activity in the past 30 days.

We use a stalebot among other tools to help manage the state of issues in this project.
A stalebot can be very useful in closing issues in a number of cases; the most common
is closing issues or PRs where the original reporter has not responded.

Stalebots are also emotionless and cruel and can close issues which are still very relevant.

If this issue is important to you, please add a comment to keep it open. More importantly, please add a thumbs-up to the original issue entry.

We regularly sort for closed issues which have a stale label sorted by thumbs up.

We may also:

  • Mark issues as revivable if we think it's a valid issue but isn't something we are likely
    to prioritize in the future (the issue will still remain closed).
  • Add a keepalive label to silence the stalebot if the issue is very common/popular/important.

We are doing our best to respond, organize, and prioritize all issues but it can be a challenging task,
our sincere apologies if you find yourself at the mercy of the stalebot.

@stale stale bot added the stale A stale issue or PR that will automatically be closed. label Jan 8, 2022
Copy link
Contributor

@jeschkies jeschkies left a comment

Choose a reason for hiding this comment

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

Thanks! I just cannot find where the error metric is increased or HTTP 5xx is returned.

pkg/storage/chunk/cache/background.go Show resolved Hide resolved
pkg/storage/chunk/cache/instrumented.go Outdated Show resolved Hide resolved
@stale stale bot removed stale A stale issue or PR that will automatically be closed. labels Jan 10, 2022
liguozhong and others added 2 commits January 11, 2022 12:43
Co-authored-by: Karsten Jeschkies <k@jeschkies.xyz>
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
Copy link
Member

@owen-d owen-d left a comment

Choose a reason for hiding this comment

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

Nice work. I'm happy to merge this once the merge conflicts/etc are addressed.

…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
…conds_bucket" ‘status_code’ label always equals "200" grafana#4891
@liguozhong
Copy link
Contributor Author

Nice work. I'm happy to merge this once the merge conflicts/etc are addressed.

done,thanks

Copy link
Member

@owen-d owen-d left a comment

Choose a reason for hiding this comment

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

One small suggestion, then LGTM. Thanks for all the great contributions!

pkg/querier/queryrange/roundtrip.go Outdated Show resolved Hide resolved
liguozhong and others added 2 commits January 14, 2022 23:47
Co-authored-by: Owen Diehl <ow.diehl@gmail.com>
@owen-d owen-d merged commit 2c20ce6 into grafana:main Jan 14, 2022
@liguozhong
Copy link
Contributor Author

liguozhong commented Jan 17, 2022

thanks all,status_code = 500 now.

sum(rate(loki_cache_request_duration_seconds_count{status_code!="200"}[2m])) by (app,name,method,status_code)>0
alert
image
dadashboar
image

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.

None yet

3 participants