Quality: Silver Tier.
🐙 userver provides sqs::JsonClient, an Amazon SQS-compatible client for the AWS JSON protocol.
The client uses AWS SDK SQS request/result types (Aws::SQS::Model::*) and sends HTTP through clients::http::Client. It does not inherit Aws::SQS::SQSClient and does not use the AWS HTTP client or AWS thread-pool async API.
Enable the library when building userver (USERVER_FEATURE_SQS, off by default). See Build options.
In a service:
The library depends on AWS SDK core/sqs and userver::core.
Aws::InitAPI is not required: the client uses AWS request/result types as DTOs and signs requests with userver crypto. JsonClient does not own the HTTP client; clients::http::Client must outlive it.
Call SQS methods from a userver coroutine: they perform HTTP via clients::http::Request::perform().
JsonClient takes clients::http::Client&, sqs::Credentials and sqs::ClientSettings.
endpoint : SQS-compatible JSON API URL. Required.
region : Signing region for SigV4. Required.
timeout : Whole HTTP request timeout, including long polling on ReceiveMessage.
verify_ssl : TLS certificate verification for the userver HTTP client.
If credentials are non-empty, requests are signed with AWS SigV4 using userver crypto. If they are empty, the request is sent unsigned.
The client currently implements the JSON protocol for:
AddPermission, ChangeMessageVisibility, ChangeMessageVisibilityBatch, CreateQueue, DeleteMessage, DeleteMessageBatch, DeleteQueue, GetQueueAttributes, GetQueueUrl, ListDeadLetterSourceQueues, ListQueueTags, ListQueues, PurgeQueue, ReceiveMessage, RemovePermission, SendMessage, SendMessageBatch, SetQueueAttributes, TagQueue, UntagQueue.
See also sqs::JsonClient.