-
Notifications
You must be signed in to change notification settings - Fork 77
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
feat: Add new metrics for spending plans #2932
Conversation
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
…) in localLRUCache#keys() Signed-off-by: Victor Yanev <[email protected]>
…pec.ts Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
…tent Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
…metrics-for-spending-plans Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
Signed-off-by: Victor Yanev <[email protected]>
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.
LGTM, 2 nits (or questions).
packages/relay/src/lib/db/repositories/hbarLimiter/hbarSpendingPlanRepository.ts
Show resolved
Hide resolved
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.
Great work! Left some questions
packages/relay/src/lib/db/repositories/hbarLimiter/hbarSpendingPlanRepository.ts
Outdated
Show resolved
Hide resolved
packages/relay/src/lib/db/repositories/hbarLimiter/hbarSpendingPlanRepository.ts
Show resolved
Hide resolved
Signed-off-by: Victor Yanev <[email protected]>
…ns' into add-new-metrics-for-spending-plans Signed-off-by: Victor Yanev <[email protected]>
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.
LGTM
packages/relay/src/lib/db/repositories/hbarLimiter/hbarSpendingPlanRepository.ts
Show resolved
Hide resolved
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.
LG.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2932 +/- ##
==========================================
- Coverage 89.59% 89.53% -0.06%
==========================================
Files 40 56 +16
Lines 3056 3794 +738
Branches 632 772 +140
==========================================
+ Hits 2738 3397 +659
- Misses 274 350 +76
- Partials 44 47 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Description:
This PR adds new metrics for spending plans which are tracked dynamically in the
HbarLimitService
:dailyUniqueSpendingPlansCounter
: Tracks the number of unique spending plans used daily. (per subscription type)averageDailySpendingPlanUsagesGauge
: Tracks the average daily spending plan usages. (per subscription type)Related issue(s):
Fixes #2933
Notes for reviewer:
Checklist