domain-trace-stream

0.0.4 • Public • Published

domain-trace-stream Build Status

Provides an event stream with all the interesting IO events.

Install

$ npm install domain-trace-stream

Use

var DomainTraceStream = require('domain-trace-stream');
 
var stream = DomainTraceStream();

Or, with options:

var stream = DomainTraceStream({
  maxQueue: 1000 // default value
});

The stream emits objects like this:

{
  event: 'http-client-request-begin',
  trace_id: '1b506b1b-0dd9-4d18-957e-7e1c5e6bf0b3',
  time: 1363873938335518,
  timeDiff: 194623,
  method: 'GET',
  path: '/search.json',
  headers: {
    "host": "search.twitter.com",
    "content-type": "application/json"  
  },
  host: "search.twitter.com"
}

The emitted events are:

  • http-client-request-begin
  • http-client-request-end
  • http-client-response-begin
  • http-client-response-end
  • http-server-request-begin
  • http-server-request-end
  • http-server-response-end

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.4
    2
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.4
    2
  • 0.0.3
    0
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i domain-trace-stream

Weekly Downloads

2

Version

0.0.4

License

MIT

Last publish

Collaborators

  • pgte