InterviewBuddy
All interview questions

How can blocking code affect unrelated Node.js requests?

Intermediate

Answer

A long synchronous task occupies the event-loop thread and delays other callbacks and requests sharing it.

Explanation

An async function can still block when it performs expensive synchronous computation.

Example

Large synchronous JSON processing delays an unrelated health request.