Why Use Version Cooldown?
Version cooldown helps you:- Reduce deployment frequency - Batch multiple rapid releases into fewer deployments
- Decrease infrastructure load - Avoid constant rolling updates from CI/CD pipelines
- Improve stability - Give each deployment time to prove itself before the next
- Save resources - Reduce compute spent on deployment overhead
Configuration
- Terraform
- API
duration (e.g.,
"1h", "30m", "90s"). This is converted to seconds internally.Properties
Minimum seconds that must pass since the currently deployed (or in-progress)
version was created before allowing another deployment. Set to
0 to disable.How It Works
Version cooldown checks if enough time has elapsed since the currently deployed (or in-progress) version was created, not the time gap between version creation times:- Find reference version: The currently deployed or in-progress version (in-progress takes precedence)
- Calculate elapsed time: Time since the reference version was created (using current time)
- Apply cooldown: If elapsed time >= interval, allow any version; otherwise, deny
Example Timeline
Common Patterns
Hourly Batching
Deploy at most once per hour:- Terraform
- API
Per-Environment Cooldown
Different intervals for different environments:- Terraform
- API
Combined with Other Rules
Use cooldown alongside other policy rules:With Deployment Windows
Combine cooldown with deployment windows for comprehensive control:Weekly Scheduled Deployments
Deploy updates on a specific day (e.g., every Monday):Behavior Details
Version Selection
When a candidate version fails cooldown:- Ctrlplane tries the next older version
- This continues until a qualifying version is found
- If no versions qualify, the release target waits
Same Version Redeploys
Redeploying the currently deployed version is always allowed, regardless of cooldown settings. This enables:- Manual re-runs of failed deployments
- Rollback-and-redeploy workflows
- Configuration-only changes - Deploy the same version with updated configuration immediately, bypassing cooldown
Urgent Deployments
For urgent deployments that need to bypass cooldown (e.g., security patches, critical fixes):- Same-version redeploy: If the urgent change uses the same version ID, it automatically bypasses cooldown
- Policy Skip: Create a PolicySkip to bypass cooldown for a specific version. This allows urgent deployments while maintaining cooldown for regular releases
In-Progress Deployments
If a deployment is in progress, the cooldown uses that version as the reference:- Prevents deploying a newer version while one is still rolling out
- Ensures sequential deployments respect the interval
Best Practices
Interval Guidelines
| Use Case | Suggested Interval | Notes |
|---|---|---|
| High-frequency CI/CD | 15-30 minutes | Balance freshness vs churn |
| Standard services | 1-2 hours | Reasonable batching |
| Stable/low-priority | 4-24 hours | Significant batching |
| Development/staging | 5-15 minutes | Faster feedback loops |
Recommendations
- ✅ Start with shorter intervals and increase as needed
- ✅ Use longer intervals for production vs staging
- ✅ Combine with gradual rollouts for safer deployments
- ✅ Monitor deployment frequency to tune intervals
- ✅ Use same-version redeploys for urgent configuration changes
- ✅ Use PolicySkip for urgent deployments that need to bypass cooldown
- ❌ Don’t set intervals so long that critical fixes are delayed
- ❌ Don’t use cooldown on environments that need immediate updates
- ⚠️ Ensure deployment windows are long enough for gradual rollouts to complete
Next Steps
- Policies Overview - Learn about policy structure
- Gradual Rollouts - Control deployment pace
- Deployment Window - Time-based deployment control