mirror of
https://github.com/floci-io/floci.git
synced 2026-11-25 14:57:54 -05:00
* fix(sqs): honor MaximumMessageSize attribute on SendMessage SendMessage previously enforced a hard-coded 256 KiB limit regardless of the queue's MaximumMessageSize attribute, and the error text always referenced 262144 bytes. Two behavioral problems: - Queues created with MaximumMessageSize=1048576 still rejected payloads over 256 KiB. - The size check only inspected the message body (in chars), not body bytes plus message attribute name/type/value bytes, the formula AWS uses to compute total message size. Both are now fixed: SendMessage reads the queue's MaximumMessageSize attribute (clamped to AWS's 1024..1048576 range), computes total size as UTF-8 body bytes + per-attribute (name + type + value) bytes, and reports the queue's configured limit in the error message. Refs #768. * fix(sqs): clamp MaximumMessageSize to AWS range, rename test var Address PR review feedback: - parseMaxMessageSize now clamps out-of-range values to [1024, 1048576] instead of silently falling back to the service default, matching the PR description and avoiding surprising behavior for queues configured with values just outside the AWS range. - Rename misleading test variable halfMeg (300 KiB body) to body.