-
Notifications
You must be signed in to change notification settings - Fork 121
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
PR for otelp-metrics #108
PR for otelp-metrics #108
Conversation
It looks great so far. |
I agree, the issue I ran into was using them as default values for the sharedMeterState's constructor, which would have required them to be public since they would be available in the constructor definition. |
I'm looking for some guidance in the toProtoMetric method in Sources/Exporters/OpenTelemetryProtocol/metric/MetricsAdapter.swift I'm not seeing a way to set min/max values. The closest proto metric I could find for the summary metrics was a histogram. I was thinking that the explicitBounds might satisfy the "min/max" issue, but I don't think that's quite right. Would exemplars be the means to capture the min max values? |
23632f8
to
e476aa7
Compare
and stubbed MetricsAdapter & OtelpMetricExporter
- Made MeterSdkProvider init mimic the TraceProvider init I decided to change the MetricSdkProvider.init method to take shared state objects as parameters, since this is how the TraceProvider operates. Alternatively, I could have move the default values into the MeterSharedState construction, but that would require making the NoopMetricProcessor & NoopMetricExporter public, which I'm not against, but seemed intentionally private. - replaced MeterRegisteryKey with InstrumentationLibraryInfo - Injected Resource into the MetricSdk stack I followed the same pattern as with the Trace Sdk.
e476aa7
to
d638ad2
Compare
Sorry for the delay in reviewing, i was OOO since last Wednesday. |
Thanks a lot for your contribution. |
I'll make sure I use swiftformat in the future! I'm not able to merge however; take it away! |
I'm opening this draft PR to get some feedback on the changes I've made to the existing api to support the otelp for metrics.
Here are key notes for these changes: