Configure health endpoints in Cratis Chronicle Server
By default Chronicle serves its health check on the main port (35000) — the same port that carries gRPC, the Workbench, the REST API and OAuth. The main port uses TLS by default, multiplexing HTTP/2 and HTTP/1.1 via ALPN. In development that TLS certificate is self-signed and generated automatically. If tls.enabled=false, the main port instead serves cleartext HTTP/2 only; probes on it must support HTTP/2.
That is exactly where orchestrator and load-balancer probes run into trouble. A health probe that has to speak TLS — and sometimes validate the certificate — against a port that may be serving a self-signed certificate is awkward at best and broken at worst. The dedicated health port removes that friction: it publishes the health endpoint on its own HTTP/1.1 port where you can turn TLS off.
Liveness and readiness
Section titled “Liveness and readiness”Chronicle binds the main and configured dedicated health listeners before starting the Orleans silo.
| Path (default) | Meaning |
|---|---|
/health/live |
Returns 200 once the listener accepts requests, even during silo startup. Use for startup and liveness probes. |
/health |
Readiness: startup has completed, the host has started, and shutdown has not begun. Existing storage checks must also pass. Returns 503 otherwise. |
/health/ready |
Same checks and status as /health. |
The readiness body is the aggregated status: Healthy, Degraded or Unhealthy, or Standby while an
opted-in standby node waits for the single-writer lease.
A different healthCheckEndpoint moves all three routes: /probe also exposes /probe/live and /probe/ready. All three remain available on an exclusive health port.
Until ready, the kernel refuses non-health traffic, including the Workbench and static files, with HTTP 503 and Retry-After, or gRPC Unavailable. Catch-up that continues in the background after startup does not hold readiness back. A startup failure still fails the host.
Kernel overload
Section titled “Kernel overload”The kernel-overload check turns readiness Degraded when a silo is overloaded, with the reason in the response, for example:
DegradedThe kernel is overloaded: The oldest call to IProjectionsManager (the-store) has been waiting 40 s (limit 15 s)A silo is overloaded when, for one grain type, the oldest call it has made to that grain type that has not been answered has waited longer than overload.maxOldestPendingCallAgeSeconds (15), more than overload.maxPendingCalls (2000) such calls are waiting, or more than overload.maxRunningCalls (2000) calls are running on this silo’s grains of that type. The numbers are counted by the silo itself, in memory, so the check answers while the grains are saturated. It clears once the silo has stayed under every limit for overload.recoverySeconds (30): it reports Degraded with the reason recovering until then, so a silo hovering around a limit does not flap.
Degraded stays HTTP 200: the other silos are probably as busy, and taking this one out of rotation would only push its clients onto them. The report is for people and for the dashboards and alerts built on cratis.chronicle.kernel.load_status. Connected clients are told as well: the keep-alive the kernel pushes carries the status, and the .NET client logs when the kernel turns busy and when it recovers. Set overload.enabled to false to stop evaluating the limits; the metrics are still produced.
The Diagnostics query service, GetKernelBusiness, answers an administrator with what the silo that served the request is busy with: its status and reasons, the grain types it waits on the longest with the age of the oldest queued call, its open streams, and the observer jobs it runs by event store, namespace and type.
MongoDB health
Section titled “MongoDB health”The mongodb check reads the shared MongoDB driver’s monitored cluster state. It does not create a
client, borrow a pool connection or run a database command. A connected writable server is healthy;
connected servers without a writable server are degraded; no connected servers is unhealthy, with
heartbeat failures included in the description. This reflects the last monitored state, not an active
query or available pool capacity. See MongoDB connection pool.
Always use /health/live for liveness, not /health or /health/ready: storage trouble should affect
readiness, not restart a running process. With a custom endpoint, use its /live subpath.
Configuration
Section titled “Configuration”Set a health section with a port to expose the health endpoint on a dedicated port. When port is not set, nothing changes — the health endpoint stays on the main port.
{ "port": 35000, "healthCheckEndpoint": "/health", "health": { "port": 8080, "tls": false }}Environment variables
Section titled “Environment variables”Cratis__Chronicle__Health__Port=8080Cratis__Chronicle__Health__Tls=falseProperties
Section titled “Properties”| Property | Type | Default | Description |
|---|---|---|---|
| health.port | number | null | Dedicated port for the health endpoint. When not set, the health endpoint is served on the main port. |
| health.tls | boolean | true | Whether the dedicated health port uses TLS. Only applies when health.port is set. |
| health.exclusive | boolean | false | Whether the dedicated health port serves only the health endpoint, answering 404 for everything else. Only applies when health.port is set. |
The endpoint path is the shared healthCheckEndpoint (default /health), so with the configuration above the health endpoint is reachable at http://<host>:8080/health.
Behavior
Section titled “Behavior”health.portnot set — the health endpoint is served on the main port (35000), using HTTPS by default or h2c whentls.enabled=false, alongside all other traffic.health.portset — the health endpoint is additionally served on that dedicated HTTP/1.1 port. gRPC is never exposed on it, because gRPC needs HTTP/2 and the dedicated port serves HTTP/1.1 only.health.tlsfalse — the dedicated port serves HTTP/1.1 in cleartext. It does not change the main port’stls.enabledsetting. Whenhealth.tlsremains true, the dedicated port requires a certificate from top-leveltls, even if the main port has TLS disabled; without it, startup fails.health.exclusivetrue — the dedicated port answers only the health endpoint and its/liveand/readysubpaths; every other path returns 404 on that port. Off by default, so enabling it never changes an existing deployment silently.health.portequal to the main port — treated as not set, since a second listener cannot bind the port the main listener already owns.
Single-writer lease readiness
Section titled “Single-writer lease readiness”With Localhost clustering on persistent storage, the default single-writer lease registers the
single-writer-lease health check (tagged ready). It is healthy only while this process holds the
lease. Losing ownership or reaching TTL/2 without a confirmed renewal makes it unhealthy and initiates
shutdown. It is not registered for MongoDB clustering, InMemory storage or an explicitly disabled lease.
A node still waiting for acquisition has not completed silo startup and is not ready, unless standby is
enabled. With clustering.singleWriterLease.standby set to true, /health and /health/ready return
200 with the body Standby from the moment the node starts waiting for the lease until its startup
has completed; the checks involved report Degraded with a standby description. In standby the node
still refuses all non-health traffic with HTTP 503 and Retry-After, or gRPC Unavailable. Once startup
completes the body is Healthy (or Degraded for other reasons, as before). If startup has not completed
clustering.singleWriterLease.standbyStartupTimeout (default 10 minutes) after the node took the lease,
readiness reports 503 Unhealthy instead, so a stuck startup does not look ready. Because the body
Standby is a 200, alert on how long a node stays in standby rather than on the status code alone. See
Standby for start-before-stop rollouts.
Storage authorization
Section titled “Storage authorization”The storage-authorization check (tagged ready) reports Degraded while a storage permission failure is recorded. HTTP stays 200, keeping the kernel in rotation. The log entry names the database, collection, and refused operation without exposing connection details.
The failure clears after the next successful access completes index setup for that collection. If database names differ from those granted to the storage user, check the database-name prefix.
Restricting the dedicated port to health only
Section titled “Restricting the dedicated port to health only”The dedicated port is an additional listener on the same application rather than a separate, health-only server. By default the other HTTP/1.1 endpoints (Workbench, REST API, OAuth) are therefore reachable on it too, so the default posture is to treat it as an internal, cluster-local probe port and not expose it publicly, especially with TLS disabled.
Set health.exclusive to true to close that off. The port then serves the health endpoint and its /live and /ready subpaths and nothing else — every other path gets a 404:
{ "health": { "port": 8080, "tls": false, "exclusive": true }}The restriction keys on the local port the connection was accepted on, which a client cannot influence. It is not derived from the Host header or any X-Forwarded-* header, so a request arriving on the main port cannot dress itself up as a health-port request or vice versa. The main port is never restricted, and the option does nothing unless a dedicated health.port is configured and differs from the main port.
It defaults to false so that enabling a dedicated health port never silently removes endpoints from an existing deployment; turn it on deliberately when the probe port is reachable from somewhere the Workbench and API should not be.
Once it is on, the Workbench is served from the main port only. A reverse proxy or ingress that routes Workbench traffic to the health port gets 404 and has to target the main port instead, over HTTPS or, with tls.enabled=false, over h2c. Workbench configuration shows that setup.
Why a plaintext health port helps in Kubernetes
Section titled “Why a plaintext health port helps in Kubernetes”Kubernetes probes and self-signed certificates do not always get along, and the details are easy to get wrong.
The kubelet’s own HTTP probes, when configured with scheme: HTTPS, skip TLS certificate verification — so a self-signed certificate technically works for kubelet liveness, readiness and startup probes. If the kubelet were the only thing probing Chronicle, the main TLS port would be fine.
In practice it usually is not the only thing. Many deployments front the pod with a cloud load balancer, ingress controller, service mesh or managed health check, and those probers commonly do validate the certificate — and reject a self-signed one. Probes also cannot present a client certificate, so mutual TLS is not an option for them. The result is that “the pod is healthy but the probe fails” class of problem, caused entirely by certificate validation rather than by Chronicle’s actual health.
Publishing the health endpoint on a dedicated plaintext port sidesteps certificate validation for every kind of prober:
{ "health": { "port": 8080, "tls": false }}startupProbe: tcpSocket: port: 35000livenessProbe: httpGet: path: /health/live port: 8080 scheme: HTTPreadinessProbe: httpGet: path: /health port: 8080 scheme: HTTPgRPC clients keep using the main port — gRPC is never served on the dedicated HTTP/1.1 port — while the probes target the dedicated port.
Use an HTTP startup probe on /health/live at port 8080 instead of TCP if preferred. Readiness must use /health or /health/ready, never a TCP probe. Raising failureThreshold is not the fix for startup restarts caused by backlog: the listener binds independently of silo startup, and the readiness endpoint deliberately remains unready until that startup finishes.
Related pages
Section titled “Related pages”- TLS Configuration (Server) for configuring the main port’s certificate.
- Port Reference for the full list of ports Chronicle exposes.
- Root Properties for the
healthCheckEndpointpath. - Run Chronicle on Azure for what the health check covers on Azure SQL and PostgreSQL.