feat: add synchronous gauge#1718
Conversation
kaylareopelle
left a comment
There was a problem hiding this comment.
Thanks for opening this, Xuan! Even more reason to get #1604 merged.
kaylareopelle
left a comment
There was a problem hiding this comment.
I'm going to mark this as "request changes" because I don't think we should merge this in until it uses LastValue as the default aggregation.
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
|
👋 This pull request has been marked as stale because it has been open with no activity. You can: comment on the issue or remove the stale label to hold stale off for a while, add the |
…uby into issues-1704
|
I'd like to make my interest in this known. I'm in the process of moving all my production applications from Datadog to self-hosted Signoz, which rely on OTel providers. We currently have multiple areas where we report current state of things (such as background queue size and latency) via gauge metrics. Without this Gauge metric, I'm not able to complete the migration. So would be very keen to see this completed in a future release. |
|
Updated the aggregation to last value. Updated the test case. |
metrics_sdk/test/opentelemetry/sdk/metrics/instrument/gauge_test.rb
Outdated
Show resolved
Hide resolved
| # TODO: When the metrics SDK stabilizes and is merged into the main SDK, | ||
| # we can leverage the SDK Internal validation classes to enforce this: | ||
| # https://github.com/open-telemetry/opentelemetry-ruby/blob/6bec625ef49004f364457c26263df421526b60d6/sdk/lib/opentelemetry/sdk/internal.rb#L47 |
There was a problem hiding this comment.
Could we turn this TODO into an issue, or reference it on an existing issue?
There was a problem hiding this comment.
Sure, I will create an issue to track it (e.g. something like integrate metrics_sdk to sdk?)
There was a problem hiding this comment.
Just seeing this! Yes, I think something like that would work and add a link to this code for reference. This is a good example for a similar TODO for logs: #1739
Co-authored-by: Kayla Reopelle <87386821+kaylareopelle@users.noreply.github.com>
Description:
Add simple gauge metrics that only record last value of recording.
Closes #1704
TODO: