@swarmion/serverless-contracts
Version:
Generate and use type-safe contracts between your Serverless services.
13 lines • 925 B
TypeScript
import { SQSContract } from '../sqsContract';
import { SendMessagesBuilderOptions, SendMessagesSideEffect } from '../types';
export declare const InfiniteThroughput = 0;
/**
* creates a sendMessages side effect
* The sendMessages function will send an array of messages to the SQS queue to the full extent of its capabilities:
* - It validates the messages against the contract
* - It chunks the array of messages into batches
* - It retries with exponential backoff the elements of the batches that failed to be sent (if AWS throttles the requests for examples)
* - By default, it throws an error if one of the message cannot be sent. You can also configure it to return the failed items instead.
*/
export declare const buildSendMessages: <Contract extends SQSContract>(contract: Contract, options: SendMessagesBuilderOptions<Contract>) => SendMessagesSideEffect<Contract>;
//# sourceMappingURL=sendMessages.d.ts.map