Types¶
Not functions themselves, but the two return types that define the function-call contracts used throughout this reference.
pghf.check_result¶
The mandatory return type of every check implementation function (see Check Implementation Functions), and the value the collection engine reads back from each one.
| Field | Type | Description |
|---|---|---|
status |
text |
'COLLECTED' or 'SKIPPED' only. A check body never returns 'ERROR' itself — that's assigned automatically by the collection engine when a check's function raises an exception. |
observed |
jsonb |
The collected data for 'COLLECTED'; left empty for 'SKIPPED'. For every check whose result type isn't jsonb, this must include a "value" key holding the primary number or answer — see Metadata Columns Explained. |
note |
text |
Required (must not be empty) for 'SKIPPED', to explain why; optional for 'COLLECTED'. |
(jsonb is PostgreSQL's binary-optimised storage type for JSON — structured, JSON-shaped data. See the Glossary.)
pghf.evaluation_result¶
The mandatory return type of every custom evaluator function registered against a threshold, and the value the evaluation engine reads back from one when a threshold has one configured.
| Field | Type | Description |
|---|---|---|
severity |
text |
One of 'ok', 'info', 'warning', 'critical', 'unknown', 'not_evaluable'. |
message |
text |
A human-readable explanation of the verdict. May be empty for 'ok'. |
detail |
jsonb |
Structured supporting data — the value or values the verdict was based on. May be empty. |
Continue to Extension and Environment Detection.