Node.js là runtime JavaScript trên server, dùng V8 engine.
- Ưu điểm: non-blocking I/O xử lý nhiều requests đồng thời, cùng ngôn ngữ với frontend (JS) nên team dùng chung tooling và type definitions, npm ecosystem khổng lồ với hàng triệu packages, fit cho real-time apps (chat, notifications) nhờ event-driven model.
- Thường dùng cho API servers, microservices, BFF (Backend for Frontend) — không phù hợp CPU-intensive workloads (video encoding, ML inference) vì single-threaded event loop bị block.
Node.js is a server-side JavaScript runtime powered by the V8 engine.
- Advantages: non-blocking I/O handles many concurrent requests, same language as the frontend (JS) lets the team share tooling and type definitions, a massive npm ecosystem with millions of packages, and excellent fit for real-time apps (chat, notifications) thanks to its event-driven model.
- Commonly used for API servers, microservices, and BFF (Backend for Frontend) layers — not suitable for CPU-intensive workloads (video encoding, ML inference) because the single-threaded event loop blocks.