-
Notifications
You must be signed in to change notification settings - Fork 177
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
Init winning ticket value redeemed stat on boot #2916
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## master #2916 +/- ##
===================================================
- Coverage 56.54162% 56.52822% -0.01340%
===================================================
Files 89 89
Lines 19460 19454 -6
===================================================
- Hits 11003 10997 -6
Misses 7849 7849
Partials 608 608
Continue to review full report in Codecov by Sentry.
|
This will fix #2917. |
Thank you! So happy to see this point finally resolved! I don’t know how long I spent on Grafana trying to find the query that would give me the exact number of winning tickets, even after a server restart, without ever succeeding. |
Lol I know how you feel, when @papabear99 PR was merged it fixed the |
This commit ensures that the pending fees is displayed correctly. The 0.012 needed to be added for my orchestrator because of [this upstream bug](livepeer/go-livepeer#2916).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks @stronk-dev!
Co-authored-by: Thom Shutt <[email protected]>
What does this pull request do? Explain your changes. (required)
So before #2888 got merged, the winning ticket metric wasn't working properly. At least, when graphing the metric using
livepeer_winning_tickets_recv
you could see that it was counting them tickets, but when querying the increase over time (ie usingsum by (datacenter)(increase(livepeer_winning_tickets_recv[7d]))
) it would be short one or more tickets.On every restart of the node the prometheus counters and gauges get reset. So using
increase
is the way to correctly display an increasing counter of tickets across restarts of the nodeI am currently seeing the same behaviour with
livepeer_value_redeemed
where on the first winning ticket, it counts it as an increase of 0, but then the next ticket gets counted correctly
Here is my theory: when the node boots, not all parameters have their values initialised to 0. It seemd that
increase
does not count an increase from null -> 1, but it does count an increase from 0 -> 1This PR initialised the
value_redeemed
stat to 0 on boot, which should fix the issue i am seeingHow did you test each of these updates (required)
Not yet tested, deploying now...