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

dd-trace-js can't wrap query or execute method on [email protected] #4958

Closed
0816i opened this issue Dec 2, 2024 · 0 comments · Fixed by #4962
Closed

dd-trace-js can't wrap query or execute method on [email protected] #4958

0816i opened this issue Dec 2, 2024 · 0 comments · Fixed by #4962

Comments

@0816i
Copy link

0816i commented Dec 2, 2024

In version 3.11.5 of the mysql2 library (refer to the PR below), some dependencies have been reorganized, and the query, execute, and addCommand methods have been consolidated into the Connection class under the base directory.

Therefore, when creating hooks for the mysql2 library in datadog-instrumentations, it seems necessary to add hooks based on lib/base/connection.js for version 3.11.5.

Additionally, since the query and execute methods in lib/connection.js, lib/pool.js, and lib/pool_cluster.js also reference the query and execute methods in lib/base/connection.js, it is necessary to ensure that they are not hooked redundantly.

sidorares/node-mysql2#3081

@0816i 0816i changed the title dd-trace-js can't wrap query or execute method on [email protected] dd-trace-js can't wrap query or execute method on [email protected] Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant