-
Notifications
You must be signed in to change notification settings - Fork 63
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
Monitoring: Metrics don't appear under any resource type #79
Comments
Exporters can get access to |
I can assign this issue to you, if you're working on it. |
Yeah, I'd be happy to work on this issue. |
Hi, just to make sure I'm doing it in a preferred way, within createTimeSeries, I'm calling detectResources, which will determine if it is an AWS EC2 instance or a GCP VM instance. Then, I convert it to the correct format for Google Cloud. There is an option for the user to enter the resource themselves, so should I incorporate that somehow? |
I'd wait for @mayurkale22 to respond as well, but I believe you should primarily just be using the resource that the user has supplied themselves (in the MeterProvider constructor). While we do also want to provide the option for the resource to be auto-detected, I'm hoping / expecting this will be included as a core SDK feature rather than needing to be implemented in each exporter, see: open-telemetry/oteps#111 |
I absolutely agree with @james-bebbington. The responsibility of the exporter is only to receive the [1] https://github.com/open-telemetry/opentelemetry-js/blob/master/packages/opentelemetry-metrics/src/Meter.ts#L52 I would suggest to open issue in https://github.com/open-telemetry/opentelemetry-js repo to attach auto-detected resource in SDK. |
Thanks @james-bebbington and @mayurkale22! I just updated my PR to take the resource from the MetricProvider instead of automatically detecting it |
[Triage] I believe this was accomplished by #85 above. Much has also changed since this issue was opened. Feel free to open a new issue if this is still a problem. |
Is your feature request related to a problem? Please describe.
I was exporting my metrics to Google Cloud. When I previously used OpenCensus and the Stackdriver Exporter, I was able to see my metrics when I selected a resource type.
However, now I can only see data when I specify the "Global" resource type.
Describe the solution you'd like
Within the Stackdriver exporter code, they specify the resource type.
Currently, this repository sets the resource to "Global" with a comment in the code here to wait until the OT API exists.
It seems that the OpenTelemetry resource API exists now, so I'll try to add this feature and make a PR with this change.
The text was updated successfully, but these errors were encountered: