Your SlideShare is downloading. ×
0
node.jsserver of many uses          Mike Brevoort   Colorado Springs Open Source Users Group               23 February 2012
Mike Brevoort    @mbrevoort    work at...(though opinions expressed in this presentation are    my own and not meant to re...
agendavery brief intro to node.jsa tour of some“unconventional” uses ofnode.js * though I don’t particularly like the work...
node.jsAn Evented I/O network serverfor Javascript       created by   sponsored by       Ryan Dahl
“Most languages were designed tosolve computational problems, but      Node.js is different.   Node.js was designed from t...
generating load
Chris Johnson @mast3rof0“Mozilla uses a single nodethread to simulate 180K users! Ihave commercial testing gear thatcant d...
https://gist.github.com/1861747
interprocess RPC
DNode             async rpc through                  sockets/JSON        symmetric remote function calling        between ...
server   client
headless testing
fast headless simulatedzombie.js            browser testing    emulation
fast headless simulatedzombie.js                   browser testing  HTML5 parsing and        Cookies and Web  dealing with...
headless WebKit with         JavaScript APIFast and nativeNOT node.jsBut node is commonly used as anorchestrator
phantomjs-node   “...implements a nauseously      clever bridge between        Phantom and Node”
screenshotting
screenshot-app                   web screenshotting  curl http://localhost:3000/cnn.com > cnn.png              https://git...
webcrawling
browser APIs or   fallbacks
node-canvas HTML5 server-side canvas                 API fallback     run canvas API calls in node, send     an image back...
Deployments
Propagit multi-server git deployment                        over http                                                     ...
Propagit multi-server git deployment                          over http                                                   ...
Propagit multi-server git deployment                         over http                                                    ...
load balancing
Bouncy   programmatic http load         balancer and router         https://github.com/substack/bouncy
Bouncy   programmatic http load         balancer and router         https://github.com/substack/bouncy
network tracing
node_pcap       libpcap bindings     decode, print and analyze     packets     node makes it very nice since     each pack...
shell scripting
shell scriptingfs core library - abstract OS orshell implementation detailscan leverage the node moduleecosystemgreat if y...
fs.watch(filename, [options], listener)
Procstreams pipe-able and composable                shell scripting in node          https://github.com/polotek/procstreams
tip of the           icebergLoad generation   Browser fallbacksIPC               DeploymentTesting           Load balancin...
Thanks!Questions?     Mike Brevoort     @mbrevoort
Node.js Server of Many Uses
Node.js Server of Many Uses
Node.js Server of Many Uses
Upcoming SlideShare
Loading in...5
×

Node.js Server of Many Uses

2,712

Published on

An incomplete tour of just a few of the awesome unconventional (for a web stack) things people have built with node.js. Presented at the Colorado Springs Open Source Users Group 2/23/2012

Published in: Technology
0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
2,712
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
29
Comments
0
Likes
3
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • node is like a project manager\n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • Transcript of "Node.js Server of Many Uses"

    1. 1. node.jsserver of many uses Mike Brevoort Colorado Springs Open Source Users Group 23 February 2012
    2. 2. Mike Brevoort @mbrevoort work at...(though opinions expressed in this presentation are my own and not meant to represent Pearson)
    3. 3. agendavery brief intro to node.jsa tour of some“unconventional” uses ofnode.js * though I don’t particularly like the work conventional
    4. 4. node.jsAn Evented I/O network serverfor Javascript created by sponsored by Ryan Dahl
    5. 5. “Most languages were designed tosolve computational problems, but Node.js is different. Node.js was designed from theground up to efficiently handle thecommunication that is at the heart of modern web applications.” http://www.joyentcloud.com/products/smart-appliances/ node-js-smartmachine/
    6. 6. generating load
    7. 7. Chris Johnson @mast3rof0“Mozilla uses a single nodethread to simulate 180K users! Ihave commercial testing gear thatcant do that! #nodesummit” - 1/24/2012
    8. 8. https://gist.github.com/1861747
    9. 9. interprocess RPC
    10. 10. DNode async rpc through sockets/JSON symmetric remote function calling between processes to/from the browser via socket.io JSON protocol dnode ports in ruby, java, php, perl https://github.com/substack/dnode
    11. 11. server client
    12. 12. headless testing
    13. 13. fast headless simulatedzombie.js browser testing emulation
    14. 14. fast headless simulatedzombie.js browser testing HTML5 parsing and Cookies and Web dealing with tag Storage soups XMLHttpRequest in all DOM Level 3 its glory implementation setTimeout/ HTML5 form fields setInterval (search, url, etc) pushState, popstate CSS3 Selectors with and hashchange events some extensions alert, confirm and prompt
    15. 15. headless WebKit with JavaScript APIFast and nativeNOT node.jsBut node is commonly used as anorchestrator
    16. 16. phantomjs-node “...implements a nauseously clever bridge between Phantom and Node”
    17. 17. screenshotting
    18. 18. screenshot-app web screenshotting curl http://localhost:3000/cnn.com > cnn.png https://github.com/visionmedia/screenshot-app
    19. 19. webcrawling
    20. 20. browser APIs or fallbacks
    21. 21. node-canvas HTML5 server-side canvas API fallback run canvas API calls in node, send an image back to the client great for some mobile use cases legacy browser fallback https://github.com/LearnBoost/node-canvas
    22. 22. Deployments
    23. 23. Propagit multi-server git deployment over http drone repos/somerepo.git drone repos/somerepo.gitgit push http://hubhost:6001/ somerepo master Hub drone repos/somerepo.git drone repos/somerepo.git https://github.com/substack/propagit
    24. 24. Propagit multi-server git deployment over http deploy/ drone somerepo.ed56c...propagit deploy --hub=hubhost:6000 --secret=beepboop somerepo ed56c6e85731d412fe22cf437cb63130afc34b07 deploy/ drone somerepo.ed56c... Hub deploy/ drone somerepo.ed56c... deploy/ drone somerepo.ed56c... https://github.com/substack/propagit
    25. 25. Propagit multi-server git deployment over http deploy/ somerepo.ed56c... dronepropagit spawn --hub=hubhost:6000 --secret=beepboop somerepo ed56c6e85731d412fe22cf437cb63130afc34b07 -- node server.js 8085 deploy/ drone somerepo.ed56c... Hub deploy/ drone somerepo.ed56c... deploy/ drone somerepo.ed56c... https://github.com/substack/propagit
    26. 26. load balancing
    27. 27. Bouncy programmatic http load balancer and router https://github.com/substack/bouncy
    28. 28. Bouncy programmatic http load balancer and router https://github.com/substack/bouncy
    29. 29. network tracing
    30. 30. node_pcap libpcap bindings decode, print and analyze packets node makes it very nice since each packet is emitted as a Buffer by the EventEmitter https://github.com/mranney/node_pcap
    31. 31. shell scripting
    32. 32. shell scriptingfs core library - abstract OS orshell implementation detailscan leverage the node moduleecosystemgreat if you need to do I/O beyondfilesystemnpm client
    33. 33. fs.watch(filename, [options], listener)
    34. 34. Procstreams pipe-able and composable shell scripting in node https://github.com/polotek/procstreams
    35. 35. tip of the icebergLoad generation Browser fallbacksIPC DeploymentTesting Load balancingScreenshotting Network tracingWebcrawling Shell scripting
    36. 36. Thanks!Questions? Mike Brevoort @mbrevoort
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×