StateReplicator.getCopyStream 方法


Gets copy stream

public OperationStream getCopyStream()


The returned CopyStream contains OperationData objects that implement Operation. The OperationData objects are obtained from the CopyState OperationDataStream that the Primary replica returns from getCopyState(SequenceNumber upToSequenceNumber, OperationDataStream copyContext). When a replica is created and has to catch up, it should obtain the CopyStream and begin to send, apply, and acknowledge the Copy objects that implement Operation. In parallel, the replica responds to the corresponding getCopyContext() and getNextAsync(CancellationToken cancellationToken)calls. The stream is empty when the returned Operation method is null.