lamberjack
v1.2.1
Published
Use inside a Lambda function to send logs to Firehose
Downloads
3
Readme
lamberjack
Ship your CloudWatch logs to Firehose for centralized logging, etc.
Usage
lamberjack(event, options)
This library comes with sensible defaults, the only option required is the deliveryStreamName.
const lamberjack = require('lamberjack')
module.exports.handler = (event, context, callback) => {
lamberjack(event, { deliveryStreamName: 'test' })
.then(() => callback())
.catch(e => callback(e))
};
Options
(as seen: default values)
{
retry: {
delay: 200, // milliseconds, used exponentially in backoff
limit: 3 // number of retries
},
firehose: undefined // a custom firehose client to use
transform: undefined // try to parse the JSON record, or { message } if not parsable
}