We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Would like automatic instrumentation for the MariaDB package.
https://www.npmjs.com/package/mariadb
I've forked the repo and am looking into how difficult this would be to implement.
The text was updated successfully, but these errors were encountered:
Any updates in this?
Sorry, something went wrong.
We are moving off of MariaDB so this is not a priority for us anymore. We implemented our own instrumentation using Sequelize hooks.
const sqlSummary = require("sql-summary"); sequelizeClient = new Sequelize(dbConfig); sequelizeClient.addHook("beforeQuery", function(options, query) { const dbSpan = tracer.startSpan( null, { tags: { type: "db", subtype: "mariadb", action: "query" } } ); options.context = { dbSpan: dbSpan }; }); sequelizeClient.addHook("afterQuery", function(options, query) { if (options.context.dbSpan) { if (query.sql) { options.context.dbSpan.setOperationName(sqlSummary(query.sql)); options.context.dbSpan.setTag("query_string", query.sql); } options.context.dbSpan.finish(); } });
Successfully merging a pull request may close this issue.
Would like automatic instrumentation for the MariaDB package.
https://www.npmjs.com/package/mariadb
I've forked the repo and am looking into how difficult this would be to implement.
The text was updated successfully, but these errors were encountered: