StateReplicator.getReplicationStream 方法

定义

Gets replication stream.

public OperationStream getReplicationStream()

返回

The ReplicationStream implements OperationStream. The ReplicationStream contains OperationData objects that implement Operation. The objects are provided by the Primary replica via replicateAsync(OperationData operationData, SequenceNumber sequenceNumber, CancellationToken cancellationToken). Generally a Secondary replica should send getOperationAsync(CancellationToken cancellationToken). Although Service Fabric does not require services to do so, generally services should transfer all OperationData objects out of the copy stream first, and then transfer operations out of the replication stream. The transfer from both copies in parallel is supported but increases the complexity of applying state updates correctly and is recommended only for advanced services. The stream is empty when the returned Operation method is null.

适用于