channel9 demo of nodejs + mongodb + graphicsmagick
JavaScript
Switch branches/tags
Nothing to show
Latest commit a62d8eb Sep 18, 2012 @aheckmann readme
Permalink
Failed to load latest commit information.
lib initial commit Sep 18, 2012
public initial commit Sep 18, 2012
views initial commit Sep 18, 2012
.gitignore initial commit Sep 18, 2012
README.md readme Sep 18, 2012
package.json initial commit Sep 18, 2012
server.js initial commit Sep 18, 2012

README.md

#channel9

This is the source from this channel 9 demo.



installation

Install Nodejs, GraphicsMagick, and MongoDB.

> git clone https://github.com/aheckmann/channel9.git
> cd channel9
> npm i

running

MongoDB must already be running. Specify your connection string by set the CHANNEL9_MONGO environment variable. If not set, the application will attempt to connect to the test database on localhost:27017.

> node server.js

// passing your own connection string
> CHANNEL9_MONGO=mongodb://localhost:99999 node server.js

goals

Demonstrate the power of nodejs streams and their compatibility with both child_processes and MongoDB by streaming uploads through an express application, directly into GridFS for storage, and back out of MongoDB, through a graphicsmagick child_process with custom command line flags set, and finally piped back to an http response. This demo app was run on an Ubuntu vm created and running on Microsoft Azure.

  in
------
clients file system -> nodejs (express) application -> pipe -> gridfs


  out
------
gridfs -> pipe -> graphicsmagick -> pipe -> http response