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

translate IntGauge to Gauge in otlp_wrappers #3619

Merged

Conversation

codeboten
Copy link
Contributor

Description:
Deprecating IntGauge As per https://github.com/open-telemetry/opentelemetry-proto/blob/f3b0ee0861d304f8f3126686ba9b01c106069cb0/opentelemetry/proto/metrics/v1/metrics.proto#L156, the OTLP receiver will translate IntGauge into Gauge.

Link to tracking Issue: Part of #3534

Testing: Added a test to ensure both Gauge and IntGauge are valid Gauge after translation.

This change is built on top of #3613, will rebase once merged.

@codeboten codeboten requested a review from a team as a code owner July 14, 2021 17:05
@codeboten codeboten requested a review from owais July 14, 2021 17:05
@project-bot project-bot bot added this to In progress in Collector Jul 14, 2021
@codeboten codeboten marked this pull request as draft July 14, 2021 17:24
@bogdandrutu
Copy link
Member

Consider a rebase for this so only the new changes are shown

@codeboten codeboten force-pushed the codeboten/deprecate-intgauge branch from 09e28b2 to 5de38e4 Compare July 14, 2021 19:33
@codeboten codeboten marked this pull request as ready for review July 14, 2021 19:34
@codeboten
Copy link
Contributor Author

Consider a rebase for this so only the new changes are shown

Done!

Collector automation moved this from In progress to Reviewer approved Jul 14, 2021
}
}

func intExemplarToExemplar(src []otlpmetrics.IntExemplar) []*otlpmetrics.Exemplar { //nolint:staticcheck // SA1019 ignore this!
Copy link
Member

Choose a reason for hiding this comment

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

In a followup PR, we need to updated the change for the exemplars #2402, because we don't have DoubleExemplars anymore :)

So need to change the sed file, and regenerate the protos, and update the pdata generator to make Exemplars array of values.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see where the DoubleExemplar is in the sed file, though im not seeing where that's being utilized in the protos as is. They're all either Exemplar or IntExemplar, does the Double get dropped somewhere?

@bogdandrutu bogdandrutu merged commit 20695b1 into open-telemetry:main Jul 14, 2021
Collector automation moved this from Reviewer approved to Done Jul 14, 2021
@codeboten codeboten deleted the codeboten/deprecate-intgauge branch July 14, 2021 20:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Collector
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants