Schema definition for the Health Check Plugin, which provides health monitoring endpoints for application status and readiness checks.
Property | Value |
---|---|
Schema URL | https://rustybeam.net/schema/HealthCheckPlugin |
Parent Schema | https://rustybeam.net/schema/UtilityPlugin |
Description | Health monitoring endpoints for application status and readiness checks |
Property | Type | Cardinality | Description |
---|---|---|---|
health_endpoint | https://rustybeam.net/schema/Text | 0..1 | URL path for general health check endpoint. Defaults to "/health". Returns overall application health status. |
ready_endpoint | https://rustybeam.net/schema/Text | 0..1 | URL path for readiness check endpoint. Defaults to "/ready". Indicates if application is ready to receive traffic. |
live_endpoint | https://rustybeam.net/schema/Text | 0..1 | URL path for liveness check endpoint. Defaults to "/live". Indicates if application is alive and responding. |
detailed_checks | https://rustybeam.net/schema/Boolean | 0..1 | Whether to include detailed system information in health responses. Defaults to true. Shows disk space, memory, etc. |
check_disk_space | https://rustybeam.net/schema/Boolean | 0..1 | Whether to check available disk space as part of health checks. Defaults to true. |
min_disk_space_mb | https://rustybeam.net/schema/Number | 0..1 | Minimum required disk space in megabytes. If available space falls below this, health status becomes unhealthy. Defaults to 100MB. |
name | https://rustybeam.net/schema/Text | 0..1 | Plugin instance name for identification. Defaults to "health-check" if not specified. |
<tr itemscope itemtype="https://rustybeam.net/schema/HealthCheckPlugin">
<span itemprop="library">file://./plugins/librusty_beam_health_check.so</span>
</tr>
<tr itemscope itemtype="https://rustybeam.net/schema/HealthCheckPlugin">
<span itemprop="library">file://./plugins/librusty_beam_health_check.so</span>
<span itemprop="health_endpoint">/status</span>
<span itemprop="ready_endpoint">/ready</span>
<span itemprop="live_endpoint">/ping</span>
<span itemprop="detailed_checks">true</span>
<span itemprop="check_disk_space">true</span>
<span itemprop="min_disk_space_mb">500</span>
</tr>
<tr itemscope itemtype="https://rustybeam.net/schema/HealthCheckPlugin">
<span itemprop="library">file://./plugins/librusty_beam_health_check.so</span>
<span itemprop="health_endpoint">/health</span>
<span itemprop="detailed_checks">false</span>
<span itemprop="check_disk_space">false</span>
<span itemprop="name">simple_health</span>
</tr>
<tr itemscope itemtype="https://rustybeam.net/schema/HealthCheckPlugin">
<span itemprop="library">file://./plugins/librusty_beam_health_check.so</span>
<span itemprop="health_endpoint">/healthz</span>
<span itemprop="ready_endpoint">/readiness</span>
<span itemprop="live_endpoint">/liveness</span>
<span itemprop="detailed_checks">true</span>
</tr>
Purpose: General application health status
Use Case: Overall application monitoring, load balancer health checks
GET /health
HTTP/1.1 200 OK
Content-Type: application/json
{
"status": "healthy",
"timestamp": "2025-07-10T14:30:45Z",
"uptime_seconds": 3600,
"checks": {
"disk_space": "healthy",
"memory": "healthy"
},
"details": {
"disk_free_mb": 2048,
"version": "1.0.0"
}
}
Purpose: Application readiness to receive traffic
Use Case: Kubernetes readiness probes, traffic routing decisions
GET /ready
HTTP/1.1 200 OK
Content-Type: application/json
{
"status": "ready",
"timestamp": "2025-07-10T14:30:45Z",
"ready": true
}
Purpose: Application liveness check
Use Case: Kubernetes liveness probes, restart decisions
GET /live
HTTP/1.1 200 OK
Content-Type: application/json
{
"status": "alive",
"timestamp": "2025-07-10T14:30:45Z",
"alive": true
}
Status | HTTP Code | Description | Action |
---|---|---|---|
Healthy | 200 | All systems operational | Continue normal operations |
Degraded | 206 | Some non-critical issues | Monitor closely, may need attention |
Unhealthy | 503 | Critical issues detected | Stop traffic, investigate immediately |
This schema inherits from the UtilityPlugin schema, which provides:
logfile
- Log file pathdirectory
- Directory configurationenabled
- Plugin enable/disable stateAnd ultimately from the base Plugin schema, which provides:
library
- Plugin library pathplugin
- Base plugin reference propertyWhen detailed_checks
is enabled, the plugin performs these system checks:
detailed_checks
and check_disk_space
must be "true" or "false" if specifiedmin_disk_space_mb
must be a positive integername
property should be unique if multiple health check plugins are usedapiVersion: v1
kind: Pod
spec:
containers:
- name: rusty-beam
livenessProbe:
httpGet:
path: /live
port: 3000
initialDelaySeconds: 30
periodSeconds: 10
readinessProbe:
httpGet:
path: /ready
port: 3000
initialDelaySeconds: 5
periodSeconds: 5
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
CMD curl -f http://localhost:3000/health || exit 1
# nginx upstream health check
upstream backend {
server backend1:3000;
server backend2:3000;
health_check uri=/ready;
}
Health check endpoints can be scraped by monitoring systems:
# Monitor health status
up{job="rusty-beam"} = 1 if /health returns 200
health_check_duration_seconds = response time for /health
disk_free_bytes = available disk space from /health details
Issue | Symptom | Solution |
---|---|---|
Health check fails | 503 Service Unavailable | Check disk space, system resources |
Endpoint not responding | 404 Not Found | Verify endpoint path configuration |
Always degraded status | 206 Partial Content | Adjust min_disk_space_mb threshold |
Slow response | High latency | Disable detailed_checks or check system load |