Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Operations

This page covers the server’s health checks and request log. The installation report the server sends is set under [usage_report], the span and metric export under [telemetry], and upgrades and the support policy are on Releases, upgrades and support.

Health checks

RouteTokenAnswers
GET {base}/health/livenessnone200 while the process serves; it checks nothing.
GET {base}/health/readinessnone200 while the server serves and no readiness indicator is down, 503 otherwise, with the family’s readiness document: the state, the phase (booting, serving or draining) and each indicator’s name and state, never why.
GET {base}/healthnoneThe status of readiness with the state alone, {"state":"up"}.
GET {base}/metricsnone200 with every metric in the Prometheus text format.
GET {base}/operator/dependenciesauth.product_scope200 with the readiness document and the last outcome of every upstream the server sends to.

The routes are those of ferrohealth-server over the registry of ferrohealth-health, the ones every FerroHEALTH product serves. Readiness answers 503 until the listener is bound and from the moment SIGTERM or SIGINT arrives, so a load balancer stops sending before the drain. The open readiness route leaves out why an indicator is down; the dependency report gives the reason behind the steward scope.

The database indicator is down while no statement reaches PostgreSQL, the audit_spool indicator is down when less than a tenth of the spool’s record or byte bound is left, and the audit_outbox indicator is down while pix.audit_quarantine holds a record the repository refused. The outbox indicator is down while a due outbound message, an XCPD answer, an ITI-93 message or an ITI-10 notification, has waited past the sender’s lease and two idle wakes, which a running sender never lets happen; a subscriber or consumer that refuses its messages leaves the server ready. The dependency report names every PMIR subscriber and every HL7 v2 consumer, the consumer as mllp:// and its host:port, with the outcome of its latest message. With the HL7 v2 face on, the hl7v2_listener indicator is down while the MLLP listener is not accepting. Each check gets two seconds; one that takes longer counts as down. The dependency report sits behind the steward scope so an anonymous reader learns no endpoint. ferropix healthcheck asks the readiness route of the server on the same host and exits 1 on anything but 200: use it as the container health check.

The request log

The request log is the one of ferrohealth-telemetry that every FerroHEALTH product writes: one line per request under the tracing target ferrohealth_telemetry::request, with these fields:

FieldWhat it holds
request_idThe UUID the server minted for the request. The steward trail of GET {base}/operator/actions carries the same id; a BALP record carries the X-Request-Id of the exchange, the client’s when it sent one.
client_namedWhether the client sent an X-Request-Id of its own. Its value is echoed on the response and never logged.
methodThe HTTP method, or _OTHER for a method outside the standard set, so a client’s own token never reaches the line.
routeThe matched route template, such as /fhir/Patient/$ihe-pix, or <unmatched>.
statusThe status answered.
latency_msThe time to the response, in milliseconds.
queryThe values of the parameters telemetry.logged_query_parameters names; empty by default.
callerThe token’s client_id, or its subject when it names none, or - when the credential names neither. A request the gate refused has no caller.
domainThe identifier domains a successful feed wrote to, comma-separated. A request that wrote none has no domain.

Every request also runs inside a server span named for its method and route template, such as GET /fhir/Patient/$ihe-pix (the method alone when no route matched), with an error status on a 5xx, which [telemetry.otlp] exports. It lands in the http_server_request_duration_seconds histogram and is counted in http_server_active_requests, the requests in flight by method and scheme, both of which GET {base}/metrics serves and [telemetry.otlp] pushes.

A panic writes one error line that names the thread and the source location and leaves the panic message out, since a message can quote a patient identifier. When the panicking thread is serving a request, the line also carries that request’s request_id, so you can find the request it broke.

The line never holds the path as sent, a query string outside telemetry.logged_query_parameters, a body or a header value. A PIXm Consumer that calls $ihe-pix by GET puts the patient’s identifier in the query, and the line still names only the route template. A proxy in front of the server must keep query strings out of its own logs for the same reason. The gate of ferrohealth-smart writes its own audit line per guarded request under the target ferrohealth_smart::audit, with the same discipline.

Reporting a defect

Open an issue when a transaction answers differently from what its specification names, or identifying data reaches a log line. Never paste patient data or a real identifier. The family’s post-market procedure says how complaints and incidents are handled.