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

[express plugin] automatic metrics instrumentation #13

Closed
naseemkullah opened this issue Jan 11, 2020 · 13 comments
Closed

[express plugin] automatic metrics instrumentation #13

naseemkullah opened this issue Jan 11, 2020 · 13 comments
Labels
enhancement New feature or request never-stale up-for-grabs Good for taking. Extra help will be provided by maintainers

Comments

@naseemkullah
Copy link
Member

Describe the solution you'd like

We can draw inspiration from @yuriatgoogle's https://dev.to/yuriatgoogle/custom-metrics-in-node-js-with-opentelemetry-and-prometheus-3dbd to expose the "golden signals"

@OlivierAlbertini
Copy link
Member

Having metrics inside our plugins is definitely in the roadmap.
We are working on the express plugin (tracing part only), you can review it for helping @vmarchaud. For the metrics part, we need to wait a bit until the sdk is ready.

@naseemkullah
Copy link
Member Author

Thanks @OlivierAlbertini , if I understand correctly, the express plugin being worked on will eventually encompass both tracing and metrics data within it, that's to say there will not be a separate tracing express plugin and a separate express metrics plugin?

@OlivierAlbertini
Copy link
Member

Thanks @OlivierAlbertini , if I understand correctly, the express plugin being worked on will eventually encompass both tracing and metrics data within it, that's to say there will not be a separate tracing express plugin and a separate express metrics plugin?

yes, one plugin for both.

@naseemkullah naseemkullah changed the title prometheus/metrics express middleware [express plugin] add metrics instrumentation Jan 11, 2020
@naseemkullah
Copy link
Member Author

naseemkullah commented Jan 12, 2020

OK so this issue depends on open-telemetry/opentelemetry-js#666 and open-telemetry/opentelemetry-js#402

@naseemkullah naseemkullah changed the title [express plugin] add metrics instrumentation [express plugin] automatic metrics instrumentation Jan 27, 2020
@vmarchaud
Copy link
Member

Moving inside the contrib repo since the express plugin is now there

@vmarchaud vmarchaud transferred this issue from open-telemetry/opentelemetry-js Apr 25, 2020
@vmarchaud vmarchaud added enhancement New feature or request up-for-grabs Good for taking. Extra help will be provided by maintainers labels Apr 25, 2020
@mbecca
Copy link

mbecca commented Mar 9, 2022

Hello, is there any progress?

@legendecas
Copy link
Member

The metrics spec, JavaScript API, and SDK are under active development. I'd believe we need to wait for a (generally) stable metrics API to start the work on third-party instrumentation. (The work is being tracked at open-telemetry/opentelemetry-js#2480 and open-telemetry/opentelemetry-js#2574)

@github-actions
Copy link
Contributor

github-actions bot commented May 9, 2022

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.

@anikdas
Copy link

anikdas commented Feb 21, 2023

@legendecas as both the issues linked are now closed. Can we expect any movement on the metrics inside the express plugin?

@legendecas
Copy link
Member

@anikdas if you are using the http instrumentation, the instrumentation should start reporting HTTP metrics for you.

See more at https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-instrumentation-http/src/http.ts#L78.

@owlas
Copy link

owlas commented Jun 1, 2023

Hey @legendecas I've tried running metrics locally with:

OTEL_METRICS_EXPORTER=console

and I don't see anything showing in the console. I also don't see anything received by my collector in production.

On the other hand traces are working fine for me from the same @opentelemetry/instrumentation-http package. Is there a flag that I could have missed to ensure those histogram metrics are being captured?


Edit: just discovered this issue, is it actually not possible to configure the metrics entirely via the command line?
open-telemetry/opentelemetry-js#3193

@pichlermarc
Copy link
Member

pichlermarc commented Jun 13, 2024

Hey @legendecas I've tried running metrics locally with:

OTEL_METRICS_EXPORTER=console

and I don't see anything showing in the console. I also don't see anything received by my collector in production.

On the other hand traces are working fine for me from the same @opentelemetry/instrumentation-http package. Is there a flag that I could have missed to ensure those histogram metrics are being captured?

Edit: just discovered this issue, is it actually not possible to configure the metrics entirely via the command line? open-telemetry/opentelemetry-js#3193

Yes, automatic setup of metrics exporters via env vars this is not implemented yet. open-telemetry/opentelemetry-js#3193 tracks implementation of that.

@pichlermarc
Copy link
Member

Closing this issue as it was the request to emit metrics for express, which the @opentelemetry/instrumentation-http package now does.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request never-stale up-for-grabs Good for taking. Extra help will be provided by maintainers
Projects
None yet
Development

No branches or pull requests

8 participants