Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds a check to automatically adjust for batch size limit enforced by aws #664

Merged

Conversation

correnarsprowls
Copy link
Contributor

This addresses #663

The change to batch_send will ensure that a batch is never larger than the 256kb limit set by SQS. If the batch size is too large then it will recurse until the batch size is small enough. If a single message is larger than the batch size limit then it will display the original error message but the rest of the batch will succeed.

These changes were tested using LocalStack.

@cjlarose
Copy link
Collaborator

cjlarose commented Apr 3, 2021

This looks great! I'll do some testing locally, but I think it should go pretty smoothly.

@cjlarose cjlarose self-assigned this Apr 7, 2021
@cjlarose
Copy link
Collaborator

cjlarose commented Apr 7, 2021

I verified locally that this will correctly subdivide message batches that exceed the SQS batch message payload limit.

@cjlarose cjlarose merged commit 69cdfeb into ruby-shoryuken:master Apr 7, 2021
@cjlarose
Copy link
Collaborator

cjlarose commented Apr 7, 2021

Thanks for your contribution, @correnarsprowls!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants