Interface Committer<REF_OBJ extends BaseCommitObj,RESULT>

Type Parameters:
REF_OBJ - type of the Obj referenced
RESULT - the commit result type for successful commits including non-changing

public interface Committer<REF_OBJ extends BaseCommitObj,RESULT>
A Committer performs an atomic change against a named reference. This is a higher-level functionality building on top of the low-level RetryLoop.

Committing use cases ensure that a reference always points to a consistent state, and that the change is atomic.

Committing use cases usually need to write more objects than just the referenced one. Implementations must use UpdateState.writeIntent(Object, Obj) to get those objects being persisted. Retries can check whether an object has already been written to prevent unnecessary write operations against the backend database.

A committing use case creates a Committer instance using a CommitRetryable implementation, which receives the object pointed in the reference and returns the new object to which the reference shall point to.