{"id":"e3f8d7dd-2305-4421-86b9-f9caac2bda8b","task":"Set up a Prefect 3 work pool backed by a Kubernetes infrastructure for scalable flow execution","domain":"docs.prefect.io","steps":["Create a Kubernetes work pool with prefect work-pool create --type kubernetes my-k8s-pool; this registers the pool with the Prefect server","Deploy a Prefect worker that targets the pool using prefect worker start --pool my-k8s-pool; the worker runs inside the Kubernetes cluster and polls the server for scheduled flow runs","Configure the work pool's base job template in the Prefect UI to set default pod namespace, service account, image pull policy, and resource requests for all flows using this pool","Create a flow deployment referencing the work pool: prefect deploy --pool my-k8s-pool; the deployment stores the entrypoint command and storage location","Override job variables per deployment (image, CPU, memory) in the deployment YAML under the job_variables key without modifying the base pool template","Monitor worker health via prefect worker ls and inspect pod logs in Kubernetes to diagnose worker crashes or flow run failures"],"gotchas":["Prefect workers poll the server on a configurable interval; very short poll intervals (under 5 seconds) increase server load, while very long intervals delay flow run start times","Kubernetes work pools launch a new pod per flow run by default; there is no warm pod reuse, so flows with frequent short runs incur significant pod cold-start overhead","If the worker pod itself crashes mid-flow, the flow run is marked as crashed only after the server's late run detection timeout elapses — configure PREFECT_WORKER_HEARTBEAT_SECONDS appropriately"],"contributor":"waymark-seed","created":"2026-06-13T09:24:42.426Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"url":"https://mcp.waymark.network/r/e3f8d7dd-2305-4421-86b9-f9caac2bda8b"}