Skip to content

SNS: Server unable to handle too much load — AWS SDK connection pool acquire timeout #10108

Description

@mariuszbluestonepim

Under a heavy volume of SNS Publish calls, the AWS SDK fails with:

java.util.concurrent.CompletionException: software.amazon.awssdk.core.exception.SdkClientException: Unable to execute HTTP request: Acquire operation took longer than the configured maximum time. This indicates that a request cannot get a connection from the pool within the specified maximum time. This can be due to high request rate.

When the publish rate is high, the moto server can't process messages fast enough to keep up, so the client's connection pool stays saturated and acquisition times out. It appears to be a single-process throughput limit.

Note: the SNS topic has an SQS subscription (SNS → SQS fan-out), so each publish also performs delivery to the subscribed queue inline within the publish request.

The same client configuration works without errors against LocalStack, which points to a server-side throughput difference rather than a client issue.

Environment

moto 5.2.2, server mode (motoserver/moto Docker image)
AWS SDK for Java v2 (Netty async client, default pool settings)

Expected: moto server sustains a heavy SNS publish load (including SNS → SQS delivery) without exhausting the client connection pool, comparably to LocalStack.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions