What is NodeJS?

  • To serve requests, Node.js keeps a small thread pool.
  • When a request is received, Node.js adds it to a queue.
  • The single-threaded “Event loop,” which is the essential component, now enters the picture. This event loop will never stop waiting for requests.
  • The loop takes a request from the queue and determines if it requires a blocking input/output (I/O) action. If not, the request is processed and a response is sent.
  • The event loop assigns a thread from the internal thread pool to process the request if it requires a blocking action. There are just a few internal threads left. The worker group is a collection of auxiliary threads.
  • Once the blocking operation is completed, the event loop records blocked requests and add them to the queue. This is how it keeps its non-blocking properties.
  • Easy — Node.js is simple to get started with. It’s a great place to start if you’re new to web programming. Getting started is simple thanks to a wealth of tutorials and a vast community.
  • Scalable — It allows applications to grow in size. Because Node.js is single-threaded, it can handle a large number of simultaneous connections while maintaining good throughput.
  • Scalable — It allows applications to grow in size. Because Node.js is single-threaded, it can handle a large number of simultaneous connections while maintaining good throughput.
  • Strong backend — Node.js is developed in C and C++, making it fast and allowing for networking capability.
  • Cross-platform compatibility — allows you to use Node.js to construct SaaS websites, desktop programs, and even mobile apps.
  • Maintainable — Node.js is a simple choice for programmers because the frontend and backend could both be handled using JavaScript.
  • High performance for Real-time applications
  • Easy scalability
  • Cost-effective
  • Reduces loading time using quick caching
  • Helps in building cross-platform applications
  • Reduces performance for handling heavy computational tasks.
  • NodeJs Asynchronous programming model can make it difficult to maintain code.
  • It can allow many code changes due to unstable API.

--

--

--

Student at Sri lankan Institute Of Information Technology and working as a trainee at Inexis Consulting

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

JavaScript Start-up Performance

Animating Colors in React Native

What Makes Jamstack Service Pricing Worth It For Web Developers?

Ant Design Dynamic/Runtime Theme

You might not need Postman if you use Visual Studio Code

Generate Vue.js components from a JSON / JavaScript DOM Structure

How to migrate from LaunchDarkly to ConfigCat

cc-question-mark

https://youtu.be/FI7jP7Ds-xU

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Mohomed Irshad

Mohomed Irshad

Student at Sri lankan Institute Of Information Technology and working as a trainee at Inexis Consulting

More from Medium

Why Should You Use Node JS ?

How Node.js Works: A Look Behind The Scenes

Unit testing in Nodejs

Introduction of Node.JS