connect-pinba

Pinba middleware for Connect

Connect-pinba


Pinba middleware for Connect framework, using node-pinba.

Pinba is a MySQL storage engine that acts as a realtime monitoring/statistics server using MySQL as a read-only interface. Connect-pinba brings data automatic statistics sending to Pinba server from your node.js application.

Check out the Github repo for the source code.

You can install this module via npm:

$> npm install connect-pinba

This middleware must be on the first called.

var connect_pinba = require('connect-pinba');
var connect = require('connect');
var server = connect.createServer(
  connect_pinba({
    schema:       'http',
    server_name:  'example.com',
    pinba_server: 'pinbadb.vlan'
  }),
  function(reqres) {
      res.writeHead(200, { 'Content-Type': 'text/plain' });
      res.end('Hello World');
  }
).listen(3000);

connect_pinba take only one parameter, a hash that will be passed to Pinba.Request constructor. See node-pinba docs for detailed information.

To contribute any patches, simply fork this repository using GitHub and send a pull request to me. Thanks!

MIT license. See license text in file LICENSE.