Expand description

Functionality to reconcile commands between a COMPUTE controller and a COMPUTE instance.

The ComputeCommandReconcile struct implements GenericClient, which allow the controller to reconnect after restarts. It maintains enough state to get a newly connected instance up-to-date and matches existing installed objects with what the controller wants to provide.

ComputeCommandReconcile is designed to live in a COMPUTE instance and liberally uses assert to validate the correctness of commands. It is not intended to be part of a COMPUTE controller as it might have correctness issues.

The contract between this and the COMPUTE controller is that identifiers are not re-used and describe the same object after restarts. Failure to do so will result in undefined behavior.

The reconciliation presents to a restarted COMPUTE controller as if the COMPUTE instance was restarted as well. It responds with the expected replies after a CreateInstance command and brings the controller up-to-date by notifying it about the current upper frontiers.

Controllers should ignore all responses received before CreateInstance as those were intended for the previous instance. The implementation currently does not distinguish between buffering messages for a disconnected controller and talking to a live controller.

Structs

Reconcile commands targeted at a COMPUTE instance.