IReliableQueue<T> IReliableQueue<T> IReliableQueue<T> Interface

Definition

Represents a reliable first-in, first-out collection of objects that are persisted and replicated.

public interface IReliableQueue<T> : Microsoft.ServiceFabric.Data.Collections.IReliableCollection<T>
type IReliableQueue<'T> = interface
    interface IReliableCollection<'T>
    interface IReliableState
Public Interface IReliableQueue(Of T)
Implements IReliableCollection(Of T)

Type Parameters

T

The type of the elements contained in the reliable queue.

Implements

Remarks

Values stored in this queue MUST NOT be mutated outside the context of an operation on the queue. It is highly recommended to make T immutable in order to avoid accidental data corruption.

Transaction is the unit of concurrency: Users can have multiple transactions in-flight at any given point of time but for a given transaction each API must be called one at a time. So all Reliable Collection APIs that take in a transaction and return a Task, must be awaited one at a time.

Methods

ClearAsync() ClearAsync() ClearAsync()

Removes all state from the IReliableCollection<T>, including replicated and persisted state.

(Inherited from IReliableCollection<T>)
CreateEnumerableAsync(ITransaction) CreateEnumerableAsync(ITransaction) CreateEnumerableAsync(ITransaction)

Creates an async enumerable over the IReliableQueue<T>.

EnqueueAsync(ITransaction, T) EnqueueAsync(ITransaction, T) EnqueueAsync(ITransaction, T)

Adds an object to the end of the reliable queue.

EnqueueAsync(ITransaction, T, TimeSpan, CancellationToken) EnqueueAsync(ITransaction, T, TimeSpan, CancellationToken) EnqueueAsync(ITransaction, T, TimeSpan, CancellationToken)

Adds an object to the end of the reliable queue.

GetCountAsync(ITransaction) GetCountAsync(ITransaction) GetCountAsync(ITransaction)

Gets the number of elements contained in the IReliableCollection<T>.

(Inherited from IReliableCollection<T>)
TryDequeueAsync(ITransaction) TryDequeueAsync(ITransaction) TryDequeueAsync(ITransaction)

Tries to remove and return the object at the beginning of the reliable queue.

TryDequeueAsync(ITransaction, TimeSpan, CancellationToken) TryDequeueAsync(ITransaction, TimeSpan, CancellationToken) TryDequeueAsync(ITransaction, TimeSpan, CancellationToken)

Tries to remove and return the object at the beginning of the reliable queue.

TryPeekAsync(ITransaction) TryPeekAsync(ITransaction) TryPeekAsync(ITransaction)

Tries to return an object from the beginning of the reliable queue without removing it.

TryPeekAsync(ITransaction, LockMode) TryPeekAsync(ITransaction, LockMode) TryPeekAsync(ITransaction, LockMode)

Tries to return an object from the beginning of the reliable queue without removing it.

TryPeekAsync(ITransaction, LockMode, TimeSpan, CancellationToken) TryPeekAsync(ITransaction, LockMode, TimeSpan, CancellationToken) TryPeekAsync(ITransaction, LockMode, TimeSpan, CancellationToken)

Tries to return an object from the beginning of the reliable queue without removing it.

TryPeekAsync(ITransaction, TimeSpan, CancellationToken) TryPeekAsync(ITransaction, TimeSpan, CancellationToken) TryPeekAsync(ITransaction, TimeSpan, CancellationToken)

Tries to return an object from the beginning of the reliable queue without removing it.

Properties

Name Name Name

Gets a value indicating the unique name for the IReliableState instance.

(Inherited from IReliableState)

Applies to