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

[Koa] koa plugin instrumentation doesnt generalize http routes #222

Closed
1 of 2 tasks
AndrewGrachov opened this issue Oct 12, 2020 · 4 comments
Closed
1 of 2 tasks

Comments

@AndrewGrachov
Copy link

  • This only affects the JavaScript OpenTelemetry library
  • This may affect other libraries, but I would like to get opinions here first

having http and koa intrumentation enabled

Expectation:
I see traces grouped by koa routes

Reality:

I see every incoming http request as separate operation which is not really useable. Do I do something wrong, or this is an issue?

download (5)

@morigs
Copy link

morigs commented Oct 23, 2020

Related to open-telemetry/opentelemetry-js#897
See spec

@jmealo
Copy link

jmealo commented Oct 29, 2020

I just reviewed the tests for the koa instrumentation and it looks like this already works properly for traces (even using nested routers): https://github.com/open-telemetry/opentelemetry-js-contrib/blob/master/plugins/node/opentelemetry-koa-instrumentation/test/koa-router.test.ts#L155

It looks like this is a matter of setting the name on the request span from the koa instrumentation as it has become more generic in the http plugin.

@AndrewGrachov
Copy link
Author

@Madamas, pls confirm that you dont have this issue anymore, and we can close that :)

@Madamas
Copy link

Madamas commented Nov 1, 2020

yep, works like a charm in latest version, thanks for heads-up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants