Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/herrmannplatz/fastify-datadog
🐶 Datadog plugin for fastify
https://github.com/herrmannplatz/fastify-datadog
datadog datadog-metrics fastify fastify-plugin monitoring
Last synced: about 1 month ago
JSON representation
🐶 Datadog plugin for fastify
- Host: GitHub
- URL: https://github.com/herrmannplatz/fastify-datadog
- Owner: herrmannplatz
- License: mit
- Created: 2018-12-09T21:56:35.000Z (about 6 years ago)
- Default Branch: main
- Last Pushed: 2023-12-10T23:06:08.000Z (about 1 year ago)
- Last Synced: 2024-10-12T23:42:28.005Z (2 months ago)
- Topics: datadog, datadog-metrics, fastify, fastify-plugin, monitoring
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/fastify-datadog
- Size: 12.7 KB
- Stars: 11
- Watchers: 2
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# fastify-datadog
![CI](https://github.com/herrmannplatz/fastify-datadog/actions/workflows/release.yaml/badge.svg)
[![npm version](https://badge.fury.io/js/fastify-datadog.svg)](https://badge.fury.io/js/fastify-datadog) [![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat)](https://standardjs.com/)> 🐶 [Datadog](https://www.datadoghq.com) plugin for fastify. Influenced by [node-connect-datadog](https://github.com/AppPress/node-connect-datadog)
## Install
```
$ npm install fastify-datadog
```## Usage
```js
const StatsD = require('hot-shots')fastify.register(require('fastify-datadog'), {
dogstatsd: new StatsD()
})
```## Options
* `dogstatsd` DogStatsD client.
* `stat` *string* name for the stat. `default = "node.fastify.router"`
* `tags` *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`