1.0.0 • Published 8 years ago
eventloop-info v1.0.0
eventloop-info
Detects and measures the latency of the NodeJS event loop
api
eventLoopInfo(function(err, delay, addInfo), threshold)
fn callback err, error object, currently we aren't handle or passing errors just follwing the NodeJS standards delay integer, returns the event loop delay in ms addInfo js object*, returns an object with memory and cpu usage at the time of the blocking/delay op
threshold integer, used to set up the amount of ms to execute the fn callback, default to 10 ms
example
const eventLoopInfo = require('eventloop-info')
//
eventLoopInfo((err, delay, addInfo) => {
// delay in ms
// addInfo an js object with memory and cpu usage
})
ISC License (ISC)
1.0.0
8 years ago