Upgrade to Pro — share decks privately, control downloads, hide ads and more …

This is Node.js

This is Node.js

The talk I gave on UA Dev Club, 8-Jul-2014

Alexander Beletsky

July 09, 2014

More Decks by Alexander Beletsky

Other Decks in Programming


  1. This is Node.js

  2. ceo@likeastore.com http://beletsky.net http://twitter.com/alexbeletsky

  3. "I was concerned about the ability to program advanced push

    features into the website like I had seen in Gmail" Ryan Dahl the creator of Node.js
  4. V8 Google's open source JavaScript engine. V8 can run standalone,

    or can be embedded into any C++ application.
  5. LibUV High performance evented I/O Originally based on LibEV switch

    to LibUV with support of Windows
  6. JavaScript Dynamic, prototype-based language Highly popular due to browser programming

  7. http://jsconf.eu/2009/speakers.html

  8. Why JavaScript? functions as first-class citizen

  9. Why JavaScript? function as first-class citizen //closures..

  10. JavaScript designed for event-oriented systems There was a natural fit

    V8 + LibEV + JavaScript
  11. “Node.js is a platform for easily building scalable network applications.

    Node.js uses an event-driven (single threaded), non-blocking I/O model that makes it lightweight and efficient…” http://nodejs.org
  12. Non Blocking I/O The concept of accessing I/O without blocking

    of application
  13. https://www.flickr.com/photos/papyrist/ Line to ATM is blocking I/O

  14. Mac’s Drive is non-blocking I/O

  15. None
  16. execution started from first line.. Output:

  17. async operation started… Output:

  18. but execution goes on.. > ping Output:

  19. after ~ms file is read… > ping > pong Output:

  20. Event Driven Application flow is driven by events

  21. http://misclassblog.com/interactive-web-development/node-js/

  22. Single Threaded Single-thread programming concepts is more easy to understand.

    Applications running in single thread are lightweight and efficient
  23. “Node.js is designed for building efficient networking applications”

  24. Core components: ! • HTTP / HTTPS • TCP /

    UDP / Sockets • DNS • File System • Crypto / Arch • Events • Streams
  25. Efficiency & Scalability Build-in server, high concurrency, horizontal scalability, clustering

  26. NPM Node Package Manager - the richest collection of high

    quality open source modules
  27. None
  28. Thanks, @alexbeletsky