🐶 Datadog plugin for fastify. Influenced by node-connect-datadog
$ npm install fastify-datadog
const StatsD = require('hot-shots')
fastify.register(require('fastify-datadog'), {
dogstatsd: new StatsD()
})
dogstatsd
DogStatsD client.stat
string name for the stat.default = "node.fastify.router"
- tags ** function (req) that takes a request object, and returns tags to be added to the histogram. default = [] ** array of tags to be added to the histogram. default = []
path
boolean include path tag.default = false
method
boolean include http method tag.default = false
responseCode
boolean include http response codes.default = false