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

introduce ctats subpackage for metrics #80

Merged
merged 2 commits into from
Dec 4, 2024
Merged

Conversation

ryanfkeepers
Copy link
Contributor

@ryanfkeepers ryanfkeepers commented Nov 12, 2024

ctats (yes, pronounced "stats"; what, do you have a better name? Please, please tell me if you do...) is the OTEL metrics wrapper for clues. It seeks to reduce the current metrics interface into two basic steps: 1/ recording metrics. 2/ optional pre-registration of data-points to record.

Most of the API is designed towards simplification of the OTEL interface into something that's approachable for generic development. This introduction leaves a few things to the side for later development:

  • unit testing (I should have this in place before the PR is complete)
  • multi-thread environment safety
  • maybe auto-initialization of system runtime metrics (cpu, memory, gc, etc)
  • View configuration as part of otel meter initialization

@ryanfkeepers ryanfkeepers added the enhancement New feature or request label Nov 12, 2024
@ryanfkeepers ryanfkeepers self-assigned this Nov 12, 2024
@ryanfkeepers ryanfkeepers force-pushed the otel-metrics branch 2 times, most recently from df60632 to 59102b6 Compare November 27, 2024 17:05
Copy link

@pandeyabs pandeyabs left a comment

Choose a reason for hiding this comment

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

Looks good!

@@ -0,0 +1,144 @@
package ctats

Choose a reason for hiding this comment

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

how about cstats instead of ctats? Rolls off the tongue easier.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

honestly I don't particularly like any of these. But for the life of me I haven't been able to come up with something better.

Choose a reason for hiding this comment

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

I am okay with ctats too. Not worth worrying so much, we'll get used to it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no, no, what I mean is that I'd love to change the name. cstats is probably better, yes. I just wish there were a clearly perfect name.

Base automatically changed from otel-metrics to main December 3, 2024 21:30
ctats (yes, pronounced "stats"; what, do you have a better name?
Please, please tell me if you do...) is the OTEL metrics wrapper for
clues.  It seeks to reduce the current metrics interface into two basic
steps: 1/ recording metrics.  2/ optional pre-registration of
data-points to record.

Most of the API is designed towards simplification of the OTEL interface
into something that's approachable for generic development.  This
introduction leaves a few things to the side for later development:

- unit testing (I should have this in place before the PR is complete)
- multi-thread environment safety
- maybe auto-initialization of system runtime metrics (cpu, memory, gc,
  etc)
add unit tests for the ctats package. Found a bug along the way where we
weren't adding entries into the map for ad-hoc counter declarations.
@ryanfkeepers ryanfkeepers merged commit c756e34 into main Dec 4, 2024
1 check passed
@ryanfkeepers ryanfkeepers deleted the otel-metrics-2 branch December 4, 2024 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants