High Express Question 155 of 226

Why do request timeouts belong at nginx and in Node?

MERN Full Stack · Speak this in 60–90 seconds · Faridabad & Delhi NCR

PICTURE THIS: JAVASCRIPT EVENT LOOP

Call stackRun now
Web APIsWait (timer/fetch)
QueueCallbacks wait
LoopPull when empty

Simple meaning

A proxy timeout stops hung clients from holding sockets forever.

1

WHY — Express instead of guessing?

Why interviewers care about Express:

They are checking judgment

on Express.

A good answer names

the situation, the default choice, and one exception - that reads as experience.

Stay structured

Name the idea, why it exists, then one short example.

Close cleanly

End with when you use it and one common pitfall.

2

STEPS — What happens step by step?

Before you speak the answer, walk the interviewer through these steps:

  1. 1
    A proxy timeout stops

    hung clients from holding sockets forever.

  2. 2
    An application timeout stops

    a stuck MongoDB query from tying up the event loop indefinitely.

  3. 3
    How it works

    They should be aligned

  4. 4
    a 60s nginx timeout

    with no Node timeout still wastes worker capacity.

  5. 5
    Common mistake

    What juniors usually get wrong.

  6. 6
    Close

    When you pick this over the alternative.

3

EXAMPLE — See it in action

Here's a short line you can speak, broken into clear beats:

Say this line
“An application timeout stops a stuck MongoDB query from tying up the event loop ”
Break into beats
Anapplicationtimeoutstopsastuck
Speaking order
2987408337471632900

Note: Adapt this scaffold to your own project — keep it under 60–90 seconds.

Key takeaway

A proxy timeout stops hung clients from holding sockets forever. An application timeout stops a stuck MongoDB query from tying up the event loop indefinitely.

Chat with us