-
Notifications
You must be signed in to change notification settings - Fork 56
Implement half of weaver registry stats for V2.
#1037
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
|
|
||
| impl Refinements { | ||
| /// Refinement statistics. | ||
| pub fn stats(&self) -> RefinementStats { |
Check failure
Code scanning / clippy
this method could have a #[must_use] attribute Error
|
|
||
| impl Refinements { | ||
| /// Refinement statistics. | ||
| pub fn stats(&self) -> RefinementStats { |
Check failure
Code scanning / clippy
this method could have a #[must_use] attribute Error
| } | ||
|
|
||
| /// Returns the statistics for this registry. | ||
| pub fn stats(&self) -> RegistryStats { |
Check failure
Code scanning / clippy
this method could have a #[must_use] attribute Error
| } | ||
|
|
||
| /// Returns the statistics for this registry. | ||
| pub fn stats(&self) -> RegistryStats { |
Check failure
Code scanning / clippy
this method could have a #[must_use] attribute Error
| } | ||
| *attribute_type_breakdown | ||
| .entry(attribute_type) | ||
| .or_insert(0 as usize) += 1; |
Check failure
Code scanning / clippy
casting integer literal to usize is unnecessary Error
| } | ||
| *attribute_type_breakdown | ||
| .entry(attribute_type) | ||
| .or_insert(0 as usize) += 1; |
Check failure
Code scanning / clippy
casting integer literal to usize is unnecessary Error
| fn test_stats() { | ||
| let registry = Registry { | ||
| attribute_groups: vec![], | ||
| registry_url: "https://opentelemetry.io/schemas/1.23.0".to_string(), |
Check failure
Code scanning / clippy
to_string() called on a &str Error
| }, | ||
| }], | ||
| attributes: vec![Attribute { | ||
| key: "key".to_string(), |
Check failure
Code scanning / clippy
to_string() called on a &str Error
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #1037 +/- ##
=======================================
+ Coverage 78.7% 79.3% +0.6%
=======================================
Files 82 83 +1
Lines 6612 7122 +510
=======================================
+ Hits 5204 5654 +450
- Misses 1408 1468 +60 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Optimistically did this using some AI assistance. Still think there's room to clean up some of these statistics, but it still offers some good insights on V2.
Note: I did NOT implement any refinement based stats yet.
Example output: