Skip to main content

The readiness probe that survives a dead dependency

Challenge on lesson: Checkpoint: Production APIs

Implement readiness(checks) where checks is a dict mapping dependency names to zero-arg callables: - returns {'ready': bool, 'checks': {name: bool}} with every name included - a check that returns a truthy value is healthy; falsy is not - a check that RAISES is a dependency that is down: record False for it — the probe itself must never propagate the exception - ready is True iff every check is True - an empty checks dict is ready

Difficulty: advanced

Back to lesson: Checkpoint: Production APIs