fsm
Trigger-enforced finite state machines for application tables.
pg_fsm · Trigger-enforced finite state machines for application tables.
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 101886 | fsm | pg_fsm | 0.3 | FEAT | GPL-3.0-only | C |
PostgreSQL · 9.6, 10, 11, 12, 13, 14, 15, 16, 17, 18
Usage
Sources:
fsm Trigger-enforced finite state machines for application tables.
Enablement
Install the files for the intended server, then create fsm in the target database:
Core Workflow
The following example is taken from the reviewed upstream documentation. Adapt object names, paths, credentials, and workload values before use.
Main Objects
The reviewed install surface includes these prominent objects:
| Object | Kind | Operational role |
|---|---|---|
fsm.event | TYPE | User-facing data type created by the extension. |
fsm.add_transition | FUNCTION | Callable function from the reviewed install surface. |
fsm.add_to_table | FUNCTION | Callable function from the reviewed install surface. |
fsm.machines | TABLE | Extension-owned table; account for its data in backup and upgrades. |
fsm.run_machine | FUNCTION | Callable function from the reviewed install surface. |
fsm.add_callback | FUNCTION | Callable function from the reviewed install surface. |
fsm.append_event | FUNCTION | Callable function from the reviewed install surface. |
fsm.events_callbacks | FUNCTION | Callable function from the reviewed install surface. |
Operations and Boundaries
- The verified PostgreSQL-major evidence covers 9.6, 10, 11, 12, 13, 14, 15, 16, 17, 18; do not infer unlisted majors.
- The extension fixes or creates schema objects under
fsm; include them in privilege and backup review.