Lab: why application lifecycle should not belong to FastAPI¶
The "before" half of the post: lifespan_api.py keeps the lifecycle in FastAPI's lifespan, and
lifespan_worker.py is the worker for the same service, which has no lifespan and writes the same
plumbing again. The "after" half is the one-lifecycle lab, where the
API, a scheduler and the worker share one AppSpec.