Sunday, 4 December 2016

Node.js - Introduction

Node.js - Introduction

Node.js is a very powerful JavaScript-based framework/platform built on Google Chrome's JavaScript V8 Engine.

It is an java script technology,which we will use server side programming.
Java script majorly executed on client side.
Java script based framework and provide run time environment.

It is used to develop I/O (Input/Output) intensive web applications like video streaming sites, single-page applications, and other web applications.

Node.js is open source, completely free, and used by thousands of developers around the world and customize as per requirement.

Node js is a library and provide run time environment.

Node js is performing operations/things in server side. (it is a server side platform).

Node.js = Runtime Environment + JavaScript Library

What Is Node JS ?

Node.js is a server-side platform built on Google Chrome's JavaScript Engine (V8 Engine).
Node.js was developed by Ryan Dahl in 2009.

Node.js applications are written in JavaScript, and can be run within the Node.js runtime on OS X, Microsoft Windows, and Linux.

Node.js also provides a rich library of various JavaScript modules which simplifies the development of web applications using Node.js.

Features of Node.js

Asynchronous and Event Driven : 
All APIs of Node.js library are asynchronous.
Node.js based server never waits for an API to return data.
The server moves to the next API after calling it and a notification mechanism of Events of Node.js
helps the server to get a response from the previous API call.

Very Fast : 
Being built on Google Chrome's V8 JavaScript Engine, Node.js library is very fast in code execution.

Highly Scalable : 
Node.js uses a single threaded model with event looping.
Event mechanism helps the server to respond in a non-blocking way and makes the server highly scalable as opposed to traditional servers which create limited threads to handle requests.

Single Threaded :
Node.js uses a single threaded program and the same program can provide service to a much larger number of requests than traditional servers like Apache HTTP Server.

No Buffering : 
Node.js applications never buffer any data. These applications simply output the data in chunks.

When to use node js ?

  • For streaming or event based applications
  • Chat application 
  • Game servers
  • Streaming servers

  • Single Page Applications
  • JSON APIs based Applications
  • Data Intensive Real-time Applications (DIRT)
  • I/O bound Applications

Where Not to Use Node.js? 
It is not advisable to use Node.js for CPU intensive applications.


Post a Comment