What is the bulkhead pattern in resilience engineering?
Bulkhead: named after ship compartments that limit flooding to one section. In software, it partitions services, threads, or connections so degraded or slow dependencies cannot monopolize shared resources, protecting unrelated flows.
2 / 5
How does a thread pool bulkhead protect an application?
Thread pool bulkhead: each external service gets its own bounded thread pool. If service A becomes slow, its pool fills and calls queue or fail, but service B's pool is untouched, so callers of B continue to get timely responses.
3 / 5
What is a semaphore bulkhead versus a thread pool bulkhead?
Semaphore bulkhead: uses a counting semaphore to cap concurrent calls; the caller thread itself executes the call once a permit is acquired. Thread pool bulkhead uses a separate pool, providing true thread isolation and timeout support.
4 / 5
Why is the bulkhead pattern especially important in microservices?
Microservices relevance: in a mesh of many services sharing infrastructure, a slow payment service could exhaust a shared thread pool, making even unrelated catalog queries fail. Bulkheads provide isolation walls between service integrations.
5 / 5
How do bulkheads and circuit breakers complement each other?
Complementary resilience: bulkheads contain the blast radius by limiting resources; circuit breakers stop futile calls after failures are detected. Used together, they give comprehensive protection: limit concurrency AND fail fast when a service is down.