Top Notch Tooling with Toolbag

Colin J. Ihrig / @cjihrig

What is Toolbag?

  • "Preloaded Node.js tooling enhancements"
  • Allows additional features to be added to Node
  • Requires no changes to application code
  • Supports commands and reporting
  • Highly customizable and extendable

The Toolbag Architecture


  • Implement nearly all of Toolbag's functionality
  • Allow arbitrary code to run prior to application code
  • At startup, core invokes plugins' register() method
  • Defines commands during registration

Example Plugins

  • HTTP, UDP, and IPC reporters
  • WebSocket and IPC command interfaces
  • Policy enforcement
  • Process signaling
  • Global symbol
  • Heapdumps and CPU profiling
  • New Relic, and more!

Configuring Toolbag

  • npm install toolbag and any required plugins
  • Create .toolbagrc.js file
  • node -r toolbag app.js


  • Plain JavaScript file
  • .toolbagrc.js file in process.cwd()
  • Or, TOOLBAG_PATH environment variable
  • Exports function config(defaults, callback)
  • Configure error policy, register plugins, etc.


  • hapi plugin implementing command interface
  • Talks to BorlandCommander, a Toolbag plugin
  • Works over nes-based WebSockets
  • Big TODO list. Pull requests welcome!

It's Morphin Time

Sorry, I Meant Demo Time

In Case the Demo Didn't Work...

In Case the Demo Didn't Work...

In Case the Demo Didn't Work...

Useful Links

The End