Define the performance expectations for your flows and to enable automated alerts when those expectations are not met.
prefect.yaml
file, a .deploy
method, or the CLI:
Defining SLAs in your prefect.yaml file
Defining SLAs using a .deploy method
Defining SLAs with the Prefect CLI
Defining SLAs with the Terraform Provider
duration
: The maximum allowed duration in seconds before the SLA is violatedduration
of 600 seconds (10 minutes) the backend will emit an prefect.sla.violation
event if a flow run does not complete within that timeframe.
stale_after
: The maximum allowed time between flow runs (e.g. 1 hour
for hourly jobs)stale_after
of 1 hour.
This SLA triggers when more than an hour passes between Completed
flow runs.
within
: The amount of startup time allotted to a flow run before the SLA is violated.prefect.sla.violation
prefect.flow-run.*