Bird
0
0

How can you combine liveness and readiness probes to improve a microservice that sometimes hangs during startup but recovers later?

hard📝 Trade-off Q9 of 15
Microservices - Orchestration with Kubernetes
How can you combine liveness and readiness probes to improve a microservice that sometimes hangs during startup but recovers later?
AUse only liveness probe to delay traffic until startup completes
BConfigure readiness probe to fail until startup completes, and liveness probe to restart if hung
CUse only readiness probe to restart the container if hung
DDisable probes and rely on manual health checks
Step-by-Step Solution
Solution:
  1. Step 1: Use readiness probe to control traffic

    Readiness probe fails during startup hang, preventing traffic until ready.
  2. Step 2: Use liveness probe to detect hangs and restart

    Liveness probe detects hung state and restarts container to recover.
  3. Final Answer:

    Use readiness probe to block traffic and liveness probe to restart if hung -> Option B
  4. Quick Check:

    Readiness blocks traffic, liveness restarts hung container [OK]
Quick Trick: Readiness blocks traffic; liveness restarts stuck containers [OK]
Common Mistakes:
MISTAKES
  • Using only one probe for both purposes
  • Confusing probe roles
  • Disabling probes and losing automation

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Microservices Quizzes