What is NodeJS ?
NodeJS a language that allow you create to server using Javascript.
The OpenJS Foundation is defined NodeJS as shown in the figure below.
Feature of NodeJS
- Fast response speed
- Fast development speed(increase productivity)
- Non-blocking I/O
- Based on Single thread-event loop
- NPM(Node Package Manager)
Advantage
- If you already know Javascript, there is a little or no learnning curve, so you can quickly learn and apply server skill.
- It is asynchronous of based on event, less burden on the server.
- Based on single thread-event loop, the response speed and processing performance are high.
- Node Package Manager (NPM) provides a wide range of modules for faster development and greater efficiency
Disadvantage
- If an error occur, server is immediately stop and require very high code quality.
- Code or architecture is complicated, you will experience callback-hell.
- It is based on single thread, it is not suitable for tasks where a single operation takes a long time.
It has fatal disadvantage, but business that need to handle fast response times and large-capacity service are increasingly using them.
Netflix, Linkedin, Paypal, Uber and Groupon are using NodeJS.
Next step, I will introduce the modules required for the development environment.