LiteBus
CatalogDispatch

Inbox AWS SQS Dispatch

  • ID: dispatch.inbox.aws-sqs
  • Name: Inbox AWS SQS dispatch
  • Maturity: GA
  • Summary: Publish leased inbox envelopes to Amazon SQS queue URLs through UseAwsSqsDispatch.

What It Does

Registers TransportInboxDispatchModule with AwsSqsTransportModule. DefaultDestination is the queue URL. Shared transport inbox dispatcher publishes payload bytes and LiteBus headers as SQS message attributes.

Remote workers typically consume via SQS inbox ingress or custom consumers that accept into their inbox store.

Packages

PackageRole
LiteBus.Inbox.Dispatch.AwsSqsRegistration glue
LiteBus.Inbox.DispatchShared dispatcher
LiteBus.Transport.AwsSqsAWS SDK adapter

Requires

  • dispatch.transport-core
  • transport.aws-sqs
  • durable-core.inbox

Invariants

  • SQS has no routing key; route resolver affects attribute mapping where applicable.
  • Requeue on consumer side uses visibility timeout change (transport layer).
  • One SQS transport module per process.

Non-Goals

  • Does not configure FIFO deduplication (application queue choice).
  • Does not consume from SQS (ingress axis).

Public Surface

services.AddLiteBus(litebus =>
{
    litebus.AddAwsSqsTransport(new AwsSqsTransportOptions
    {
        Region = "us-east-1",
        LongPollWaitTimeSeconds = 20
    });

    litebus.AddInbox(inbox =>
    {
        inbox.EnableInboxProcessor();
        inbox.UseAwsSqsDispatch(
            options =>
            {
                options.DefaultDestination = "https://sqs.us-east-1.amazonaws.com/111122223333/orders";
            });
    });
});
APIRole
InboxModuleBuilder.UseAwsSqsDispatch(Action<TransportInboxDispatcherOptions>)Registers inbox transport dispatcher that requires the root SQS transport
TransportInboxDispatcher.DispatchAsync(InboxEnvelope, CancellationToken)Shared dispatch publish path

AwsSqsTransportOptions:

PropertyDefaultRole
RegionnullAWS region
ServiceUrlnullLocalStack or custom endpoint
AccessKey / SecretKeynull / nullExplicit credentials
LongPollWaitTimeSeconds20Consumer long poll wait
VisibilityTimeoutSeconds30Consumer visibility timeout
RequeueVisibilityTimeoutSeconds30Base requeue timeout
MaxRequeueVisibilityTimeoutSeconds900Max requeue timeout
RequeueBackoffMultiplier2.0Requeue backoff multiplier
PollBackoffInitial00:00:00.500Initial poll retry delay
PollBackoffMax00:00:30Max poll retry delay
PollBackoffMultiplier2.0Poll retry multiplier

Observability

SignalDetail
send {destination}Queue URL as destination; message id and messaging.system=aws_sqs attributes
litebus.transport.circuit_breaker.*Broker tag sqs (outbox failure tests exercise breaker; inbox dispatch failure mirror absent)
litebus.inbox.processor.*Standard inbox processor metrics around dispatch

SQS message attributes carry LiteBus headers mapped from envelope metadata.

Deep Docs

Test Coverage

Covered

Test methodProject
InboxModuleBuilderAwsDispatchExtensions_should_expose_use_aws_sqs_dispatchLiteBus.Inbox.UnitTests (Dispatch/AwsSqs/)
InboxDispatchExtensions_ShouldRegisterTransportDispatcherLiteBus.Durable.IntegrationTests (Registration/)
ProcessPendingAsync_ShouldPublishLeasedEnvelopeToSqsQueueLiteBus.Durable.IntegrationTests (Dispatch/Inbox/AwsSqs/) (LocalStack)

Untested

  • Inbox dispatch failure for invalid queue URL or credentials.
  • FIFO queue constraints and deduplication behavior.
  • Route override branches through resolver and tenant strategy.

Out-of-Scope

  • FIFO deduplication configuration (application queue choice)
  • Consuming from SQS (ingress.inbox.aws-sqs)

On this page