Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
bunyan-config
Advanced tools
Converts JSON configuration into a proper bunyan configuration object.
This module converts JSON configuration into a proper bunyan configuration object.
It is useful when you want/need to restrict your configuration to a JSON object,
where you cannot reference process.stdout
or instantiate plugins.
npm install bunyan-config --save
var jsonConfig = {
name: 'myLogger',
streams: [{
stream: 'stdout' // shorthand config
}, {
stream: { name: 'stderr' } // full version
}, {
type: 'raw',
stream: { // full version with params
name: 'bunyan-logstash',
// The value of `streamParams` is stream-specific.
params: {
host: 'localhost',
port: 5005
}
}
}, {
type: 'raw',
stream: {
name: 'bunyan-redis',
params: {
host: 'localhost',
port: 6379
}
}
},
serializers: {
req: 'bunyan:stdSerializers.req',
fromNodeModules: 'someNodeModule',
fromNodeModulesWithProps: 'someNodeModule:a.b.c',
custom: './lib/customSerializers:custom',
another: './lib/anotherSerializer',
absolutePath: '/path/to/serializer:xyz'
}
// or
serializers: 'module:property.parent.child' // relative and absolute module references are also supported
]};
var bunyanConfig = require('bunyan-config')(jsonConfig);
var logger = require('bunyan').createLogger(bunyanConfig);
Please submit pull requests with support for additional streams.
Any serializer exposed as a node module or as a (deep) property on any node module.
Relative module references are resolved from the current working directory.
FAQs
Converts JSON configuration into a proper bunyan configuration object.
The npm package bunyan-config receives a total of 18 weekly downloads. As such, bunyan-config popularity was classified as not popular.
We found that bunyan-config demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.