-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Mongoose tracing plugin instrumentation does not trace useful timings #4078
Comments
This issue has gone three weeks without activity. In another week, I will close it. But! If you comment or otherwise update it, I will reset the clock, and if you label it "A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀 |
It's misleading that this was closed as completed. There is still no useful tracing integration for Mongoose, despite Sentry advertising that Mongoose is auto-discovered with the Node.js performance integrations. @iker-barriocanal Can you please add the label |
Maybe somebody from @getsentry/team-web-sdk-frontend can take a look? |
Thanks for the ping @iker-barriocanal! @ptrin, there is indeed some hope ;) We're currently working on our new SDK major version v8 (#9508) where one of the core changes will be that our Node instrumentations (including DB integrations like Mongoose) will be based on OpenTelemetry. So chances are that the issue you're experiencing will be fixed with v8. We'll release a first alpha version next week and we'd love to get some feedback on it if you have time. |
I think we have a bug with auto discovery - that dynamic require needs to look at
For now you can just add
and yes as @Lms24 mentioned above with v8 this will be fixed (and the instrumentation will be higher quality!) |
Package + Version
@sentry/tracing
: 6.13.3Version:
Description
Using the mongoose tracing plugin does not produce useful data because it seems to patch functions like
.find()
which are usually chained:Calls usually look like:
However, the plugin attaches to the
find
method which returns immediately. Proof of this here:Instead of attaching to
find
, it should attach toexec
.Reference for properly instrumenting mongoose: https://github.com/aspecto-io/opentelemetry-ext-js/blob/master/packages/instrumentation-mongoose/src/mongoose.ts
Originally implemented in:
#3252
#3176
The text was updated successfully, but these errors were encountered: