KubeMQ
Client SDKsC#Reference

Queues

Durable queues and streaming — KubeMQ C# SDK reference.

Send messages with SendQueueMessageAsync, receive them with ReceiveQueueMessagesAsync, and lean on streaming helpers for high-throughput scenarios (see examples for stream send/receive, policies, and poll mode).

Simple Queues

SendQueueMessageAsync

Task<QueueSendResult> SendQueueMessageAsync(QueueMessage message, CancellationToken ct = default);

QueueMessage fields:

PropertyTypeDescription
ChannelstringTarget queue
BodyReadOnlyMemory<byte>Payload
Metadatastring?Metadata
DelaySecondsint?Initial delay in seconds
ExpirationSecondsint?TTL in seconds
MaxReceiveCountint?Retry budget
MaxReceiveQueuestring?DLQ channel

ReceiveQueueMessagesAsync

Task<QueuePollResponse> ReceiveQueueMessagesAsync(QueuePollRequest request, CancellationToken ct = default);

Each QueueMessageReceived exposes AckAsync(), NackAsync(), and ReQueueAsync(channel) for manual settlement.

Queue Streaming

Streaming APIs (upstream/downstream, ack ranges, policies) are described in the Queues examples. Use those walkthroughs for IAsyncEnumerable consumption patterns and policy configuration.

Quick Usage

Queues.cs
await client.SendQueueMessageAsync(new QueueMessage
{
    Channel = "jobs",
    Body = payload,
});

See Also

Was this page helpful?

On this page