ICountDownLatch Interface
Namespace: Hazelcast.CP
Assembly: Hazelcast.Net.dll
Represents a countdown latch which is a backed-up distributed alternative to the java.util.concurrent.CountDownLatch. It is a cluster-wide synchronization aid that allows one or more threads to wait until a set of operations being performed in other threads completes. It works on top of the Raft consensus algorithm. It offers linearizability during crash failures and network partitions. It is CP with respect to the CAP principle. If a network partition occurs, it remains available on at most one side of the partition.
public interface ICountDownLatch : ICPDistributedObject, IDistributedObject, IAsyncDisposable
Inherited Members
Methods
Name | Description |
---|---|
AwaitAsync(TimeSpan) | Waits until the latch has counted down to zero, or the specified timeout waiting time has expired. |
CountDownAsync() | Decrements the count of the latch. |
GetCountAsync() | Gets the current count of the latch. |
TrySetCountAsync(int) | Sets the count to the specified value if it is zero. |