TECHNOLOGY

FMU rollback capability: an in-memory state is not automatically a serialized checkpoint

In this article
THE QUICK TAKE

State capture and restoration are optional capabilities; byte serialization requires an additional capability and its own allocation and lifetime handling.

Ask what the rollback design actually requires

A twin coordinator wants to try a communication step, reject it and restore the component before trying different inputs. Later, the same team proposes saving that state to disk overnight. These are different requirements. A live state snapshot may support the first without providing the second. Inventory rollback, persistence and restart requirements before selecting an FMU, instead of discovering during recovery that the required state operation was never advertised.

Check capabilities before state calls

The interface schema declares canGetAndSetFMUState and canSerializeFMUState separately, both defaulting to false. The complete-state specification permits capture, restore and release only with the former capability. Serialization operations require both. A loader must inspect the selected interface’s declaration rather than assume that optional operations work because the archive is an FMU. Reject an unsupported recovery plan explicitly instead of discovering it after an expensive rejected step.

An opaque snapshot has an owner and lifetime

State capture returns an opaque snapshot that can later be restored. The specification requires restoration to leave the supplied snapshot unchanged so it can be reused. Its dedicated release operation frees associated resources. Do not write the pointer value to a checkpoint file or substitute generic memory deallocation for the FMU’s release function. Keep snapshot creation, repeated restore and final release in an ownership record so rollback does not become an accumulating resource leak.

Serialization adds a byte-buffer contract

When serialization is supported, the importer queries the required serialized size, allocates an appropriate byte vector and asks the FMU to fill it. Deserialization constructs a state snapshot from those bytes. Preserve the producing FMU identity and environment with any persistent artifact. A byte vector is a representation, not evidence that unrelated builds, platforms or models can interpret it. Any intended migration requires a separately established compatibility contract and a recovery test.

Propose a capability and recovery matrix

A proposed fixture should include an FMU without state support and one advertising the required capabilities. Verify rejection before unsupported calls. For a supported component, compare a continued branch against a restore-and-repeat branch under identical inputs, then inspect resource release. Test the serialized path separately if persistence is required. No FMU recovery experiment was run here; these checks define evidence to collect rather than claim measured checkpoint reliability.

Separate state completeness from persistence completion

The DataStates study explains why state capture and durable completion differ; stack reproducibility supports retaining build identity. FMI capability acceptance establishes which recovery operations the component promises. It does not establish filesystem durability, cross-version compatibility or physical-model accuracy. Keep those claims separate when a coordinator reports that a branch is recoverable or that a persisted initialization can be reused.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles