apm-agent-nodejs icon indicating copy to clipboard operation
apm-agent-nodejs copied to clipboard

[email protected] instrumentation

Open trentm opened this issue 4 years ago • 1 comments

https://www.npmjs.com/package/redis/v/4.0.0 was published 2021-11-25. It would be good to add support for it.

Currently in .tav.yml:

redis:
  versions: '>=2.0.0 <4.0.0'
  commands: node test/instrumentation/modules/redis.test.js

and in modules/redis.js:

module.exports = function (redis, agent, { version, enabled }) {
  if (!semver.satisfies(version, '>=2.0.0 <4.0.0')) {
    agent.logger.debug('redis version %s not supported - aborting...', version)
    return redis
  }

Note that dependabot is already suggesting that opbeans-node update to redis@4: https://github.com/elastic/opbeans-node/pull/117

trentm avatar Nov 29 '21 16:11 trentm

See also @node-redis/client: https://www.npmjs.com/package/@node-redis/client which lives here: https://github.com/redis/node-redis/tree/master/packages/client

Also this v3 to v4 migration guide: https://github.com/redis/node-redis/blob/HEAD/docs/v3-to-v4.md

trentm avatar Jan 29 '22 20:01 trentm