Skip to content

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mongodb-slow-query

A library to tail slow query on MongoDB for Node.js

Install

npm install -S mongodb-slow-query

Usage

var mongoDbSlowQuery = require('mongodb-slow-query');

var watcher = mongoDbSlowQuery.watcher({ url: 'MONGODB_URL' });
watcher.connect(function(err) {
  if (err) {
    console.error(err);
  } else {
    watcher.on('data', function(data) {
      console.info(data);
    });
    watcher.on('end', function() {
      console.info('watcher emits end.');
    });
    watcher.on('close', function() {
      console.error('watcher emits close.');
    });
  }
});

About

A library to tail slow query on MongoDB for Node.js

Resources

Stars

5 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages