# statsd-client-cached

> A caching version of statsd-client

Latest version **1.0.1** (published 2020-11-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install statsd-client-cached
pnpm add statsd-client-cached
yarn add statsd-client-cached
bun add statsd-client-cached
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2020-11-18 |
| First published | 2015-12-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 4.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Nico Kaiser |
| Maintainers | nicokaiser |

## Links

- npm: https://www.npmjs.com/package/statsd-client-cached
- Repository: https://github.com/nicokaiser/node-statsd-client-cached
- Issues: https://github.com/nicokaiser/node-statsd-client-cached/issues
- npm.io page: https://npm.io/package/statsd-client-cached

## Dependencies (1)

- [statsd-client](https://npm.io/package/statsd-client.md) ^0.4.5

## Recent versions

- 1.0.1 (latest) — 2020-11-18
- 1.0.0 — 2019-05-15
- 0.1.0 — 2017-03-22
- 0.0.1 — 2015-12-07

## README

statsd-client-cached
====================

[![NPM version](https://badge.fury.io/js/statsd-client-cached.svg)](https://www.npmjs.com/package/statsd-client-cached)
[![Dependencies](https://img.shields.io/david/nicokaiser/node-statsd-client-cached.svg)](https://david-dm.org/nicokaiser/node-statsd-client-cached)

This is a wrapper for [statsd-client](https://github.com/msiebuhr/node-statsd-client), which aggregates values and changes for a specific interval and sends them to statsd only (at most) once every interval.

Usage
-----

It is initialized and used exaclty like `statsd-client`, with an additional `flushInterval` option (default: 10).

```javascript
const SDC = require('statsd-client-cached')

const sdc = new SDC({
  host: 'statsd.example.com',
  port: 8124,
  flushInterval: 10000 // default: 10 seconds
})
```

Notes
-----

Aggragation and delaying affects increments/decrements (counters) and gauges. Timers and histograms are sent immediately (as there is no aggregation for these).

License
-------

MIT

---
_Source: https://npm.io/package/statsd-client-cached · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
