# bristol-graylog

> Graylog transport(target) for the Bristol logger

Latest version **0.0.2** (published 2019-02-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install bristol-graylog
pnpm add bristol-graylog
yarn add bristol-graylog
bun add bristol-graylog
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.2 |
| Published | 2019-02-14 |
| First published | 2019-02-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 5.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | LeMidi |
| Maintainers | lemedi |
| Keywords | Bristol, Graylog |

## Links

- npm: https://www.npmjs.com/package/bristol-graylog
- Repository: https://github.com/leMedi/bristol-graylog
- Homepage: https://github.com/leMedi/bristol-graylog#readme
- Issues: https://github.com/leMedi/bristol-graylog/issues
- npm.io page: https://npm.io/package/bristol-graylog

## Alternatives

- [cli-color](https://npm.io/package/cli-color.md) — 3.4M weekly downloads
- [log](https://npm.io/package/log.md) — 1.3M weekly downloads
- [logstash-client](https://npm.io/package/logstash-client.md) — 4.5K weekly downloads
- [@nocobase/plugin-logger](https://npm.io/package/@nocobase/plugin-logger.md) — 2.0K weekly downloads
- [child-process-debug](https://npm.io/package/child-process-debug.md) — 695 weekly downloads

## Recent versions

- 0.0.2 (latest) — 2019-02-14
- 0.0.1 — 2019-02-14
- 0.0.0 — 2019-02-14

## README

# [Graylog](https://www.graylog.org) transport for [Bristol](https://github.com/TomFrost/bristol)

Bristol transport to send events and errors to Graylog.

## Installation

You will need to install this package, as well as `[node-graylog2](https://www.npmjs.com/package/graylog2)`, which is the Graylog node.js client.

```
npm install --save bristol-graylog graylog2 bristol
```

## Getting started

```js
const bristol = require('bristol');
const graylog2 = require("graylog2");;
const bristolGraylog = require('bristol-graylog');

const target = bristolGraylog({ 
  client: new graylog2.graylog({
    servers: [ 
      { 'host': '127.0.0.1', port: 12201 }
    ],
    hostname: 'server.name', // the name of this host
                             // (optional, default: os.hostname())
    facility: 'Node.js',     // the facility for these log messages
                            // (optional, default: "Node.js")
    bufferSize: 1350         // max UDP packet size, should never exceed the
                            // MTU of your system (optional, default: 1400)
  })
})

// Add as a target with the included formatter.
bristol.addTarget(target)

// Try it out
bristol.debug('here come dat boi');
bristol.info('watch him rollin watch him go');
bristol.warn('he be rollin', { rollinWhere: 'down the street' });
bristol.error(new Error('o shit waddup'));
```
# Author

Mehdi El-Haij - [@leMedi](https://github.com/leMedi)

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