Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

couchdb-log-parse

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

couchdb-log-parse

A program for parsing CouchDB logs

  • 0.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.6K
decreased by-31.41%
Maintainers
1
Weekly downloads
 
Created
Source

couchdb-log-parse

A program for parsing CouchDB logs

Usage

var LogParse = require('couchdb-log-parse')
var parser = new LogParse()

fs.createReadStream('couchdb.log').pipe(parser)

parser.on('data', function (c) {
  // this is the raw data, don't know why you need this, but whatever
})

parser.on('message', function (message) {
  // this is probably what you want.
  // it's the parsed object with informative fields
})

Fields

The parsed messages all have these fields:

  • date The date that the log was posted
  • level Usually one of info, warn, or error
  • pid Not a real pid. Some kind of silly erlang goober.
  • type Either 'http', 'erl', or 'misc'

Depending on the type they may have the following fields as well:

http

  • ip The requesting IP. (If you're behind a proxy or load balancer, then it's not super interesting.)
  • method Something like GET, POST, PUT, etc.
  • url The url requested
  • statusCode The response status code.

erl

  • message Whatever comes before the dump. Sometimes blank.
  • dump The dumped erlang object. (If someone wants to write a parser for the erlang objdump notation, that'd be rad.)

misc

  • message Whatever it was that couldn't be parsed.

Keywords

FAQs

Package last updated on 20 May 2015

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc