Configuration
Properties
| Property | Type | Required | Description |
|---|---|---|---|
type | string | Yes | Must be "sleep" |
durationSeconds | integer | Yes | Duration to wait in seconds (1-3600) |
Response Data Available in CEL
The Sleep provider makes the following data available in your CEL success conditions:result.ok- Alwaystrueafter the sleep duration completesresult.value- The duration that was waited (in seconds)result.duration- The actual duration waited in milliseconds
Example Success Conditions
Examples
Basic Sleep
Wait for Service Stabilization
Combined with Other Metrics
Use Cases
- Service Stabilization: Wait for services to fully start up before running health checks
- Scheduled Tasks: Wait for scheduled tasks or cron jobs to complete
- Warm-up Period: Allow caches or connections to warm up before verification
- Sequential Verification: Create a delay between different verification steps
Best Practices
- Use appropriate durations: Keep sleep durations reasonable (typically 30-300 seconds)
- Combine with other metrics: Use sleep as a first step, then follow with actual health checks
- Consider deployment time: Account for how long your service takes to start
- Don’t overuse: Prefer actual health checks over sleep when possible