23.21. Class QueueStorage
Namespace: ArmoniK.Core.Adapters.Memory
Assembly: ArmoniK.Core.Adapters.Memory.dll
public class QueueStorage : IPullQueueStorage, IPushQueueStorage, IQueueStorage, IInitializable, IHealthCheckProvider
23.21.1. Inheritance
23.21.2. Implements
IPullQueueStorage, IPushQueueStorage, IQueueStorage, IInitializable, IHealthCheckProvider
23.21.3. Inherited Members
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
23.21.4. Properties
23.21.4.1. MaxPriority
Max priority supported by the queue
public int MaxPriority { get; }
23.21.4.1.1. Property Value
23.21.5. Methods
23.21.5.1. Check(HealthCheckTag)
Checks the status of a class for the given health check type.
public Task<HealthCheckResult> Check(HealthCheckTag tag)
23.21.5.1.1. Parameters
tag HealthCheckTag
Health check for which the class has to answer.
23.21.5.1.2. Returns
The result of the check containing the status of the class for the health check type.
23.21.5.2. Init(CancellationToken)
Executes an initialization process for the class
public Task Init(CancellationToken cancellationToken)
23.21.5.2.1. Parameters
cancellationToken CancellationToken
Token used to cancel the execution of the method
23.21.5.2.2. Returns
Task representing the asynchronous execution of the method
23.21.5.3. PullMessagesAsync(string, int, CancellationToken)
Gets messages from the queue
public IAsyncEnumerable<IQueueMessageHandler> PullMessagesAsync(string partitionId, int nbMessages, CancellationToken cancellationToken = default)
23.21.5.3.1. Parameters
partitionId string
ArmoniK partition name
nbMessages int
Number of messages to retrieve
cancellationToken CancellationToken
Token used to cancel the execution of the method
23.21.5.3.2. Returns
IAsyncEnumerable<IQueueMessageHandler>
Enumerator allowing async iteration over the message queue
23.21.5.4. PushMessagesAsync(IEnumerable<MessageData>, string, CancellationToken)
Puts messages into the queue, handles priorities of messages
public Task PushMessagesAsync(IEnumerable<MessageData> messages, string _, CancellationToken cancellationToken = default)
23.21.5.4.1. Parameters
messages IEnumerable<MessageData>
Collection of messages
_ string
cancellationToken CancellationToken
Token used to cancel the execution of the method
23.21.5.4.2. Returns
Task representing the asynchronous execution of the method