-
Notifications
You must be signed in to change notification settings - Fork 314
feat(hip-3-pusher): improved metrics #3243
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
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
| # labels: dex, status, error_reason | ||
| self.update_attempts_total = self.meter.create_counter( | ||
| name="hip_3_relayer_update_attempts_total", |
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.
This should have a symbol label too so we can isolate issues with particular feeds
| def _get_error_reason(self, response): | ||
| response = response.get("response") | ||
| if not response: | ||
| return None | ||
| elif "Oracle price update too often" in response: | ||
| return "rate_limit" | ||
| elif "Too many cumulative requests" in response: | ||
| return "user_limit" | ||
| else: | ||
| logger.warning("Unrecognized error response: {}", response) | ||
| return "unknown" |
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.
Would be nice to turn the output here into an enum so that we don't have to check against string values in other parts of the code
Summary
Metrics to bring more in line with price-pusher and set up dashboard: http://grafana.monster-vibes.ts.net/d/ef54niixonta8c/hip-3-relayer?orgId=1
Rationale
Observability.
How has this been tested?