SpinTheMic
Pro

Interview practice question

Graceful shutdown with in-flight work

Backend Engineering · Concurrency · Experienced

How do you implement graceful shutdown in a service with HTTP handlers, background workers and queue consumers?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Catch SIGTERM.
  • Stop accepting new requests/messages.
  • Wait for in-flight work with deadline.
  • Cancel remaining via context.
  • Close resources in order.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics