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

feat: Introduce opentel metrics to cohort sdk and banking example. #65

Merged
merged 28 commits into from
Aug 16, 2023

Conversation

fmarek-kindred
Copy link
Contributor

No description provided.

@codecov
Copy link

codecov bot commented Aug 4, 2023

Codecov Report

Patch coverage: 1.73% and project coverage change: -2.54% ⚠️

Comparison is base (e500dcc) 61.84% compared to head (168eb31) 59.30%.

❗ Current head 168eb31 differs from pull request most recent head d7e71e2. Consider uploading reports for the commit d7e71e2 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #65      +/-   ##
==========================================
- Coverage   61.84%   59.30%   -2.54%     
==========================================
  Files          89       93       +4     
  Lines        4888     5104     +216     
==========================================
+ Hits         3023     3027       +4     
- Misses       1865     2077     +212     
Files Changed Coverage Δ
packages/cohort_banking/src/app.rs 0.00% <0.00%> (ø)
...kages/cohort_banking/src/callbacks/oo_installer.rs 0.00% <0.00%> (ø)
...cohort_banking/src/callbacks/statemap_installer.rs 0.00% <ø> (ø)
packages/cohort_sdk/src/cohort.rs 0.00% <0.00%> (ø)
packages/cohort_sdk/src/model/mod.rs 0.00% <0.00%> (ø)
packages/metrics/src/lib.rs 100.00% <ø> (ø)
...ckages/metrics/src/opentel/aggregation_selector.rs 0.00% <0.00%> (ø)
packages/metrics/src/opentel/model.rs 0.00% <0.00%> (ø)
packages/metrics/src/opentel/printer.rs 0.00% <0.00%> (ø)
packages/metrics/src/opentel/scaling.rs 0.00% <0.00%> (ø)
... and 6 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

once_cell = { version = "1.18.0"}
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is not required any more, could you remove it?

@@ -93,6 +94,8 @@ impl ControlledRateLoadGenerator {
}
}

tx_output.close();
Copy link
Collaborator

Choose a reason for hiding this comment

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

👍

Copy link
Collaborator

Choose a reason for hiding this comment

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

Still a bit confused as to why drop was not working while exiting the generator. But if explicit close is working that should be good.

image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because its arc'ed?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I did check that during the review, Arc should drop the inner value if the reference count goes to 0.

And in our use case, we don't clone it. So the reference count is 1 which on exiting will become 0, and therefore drop the inner value.

image

Copy link
Collaborator

@gk-kindred gk-kindred left a comment

Choose a reason for hiding this comment

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

Thanks for updating the PR based on last discussion. Added some more minor comments, but overall really good effort !!

@fmarek-kindred fmarek-kindred merged commit e279978 into master Aug 16, 2023
2 checks passed
@fmarek-kindred fmarek-kindred deleted the feature/optel_metrics branch August 16, 2023 00:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants