Background scheduler services exceed loop intervals under database contention
warningperformanceUpdated Apr 24, 2025(via Exa)
Technologies:
How to detect:
Prefect background services (RecentDeploymentsScheduler, FlowRunNotifications, FailExpiredPauses) take longer to complete than their configured loop intervals, indicating database or resource contention. RecentDeploymentsScheduler can take 160+ seconds against a 5-second interval.
Recommended action:
These warnings are symptoms of underlying database performance issues. Address database query performance, connection pool sizing, and lock contention. Monitor whether specific services are the bottleneck. Consider increasing loop intervals as a temporary mitigation if services cannot complete in time.