Croway opened a new pull request, #30227: URL: https://github.com/apache/camel/pull/30227
JIRA: [CAMEL-27064](https://issues.apache.org/jira/browse/CAMEL-27064) - With `deleteAfterRead` or `moveAfterRead`, the `google-storage` and `minio` consumers took the object name and the bucket from the headers when the exchange completed, and `alibaba-mns` took the receipt handle from its header. A route that set the object name header (for example to write a copy of the object under another name) deleted or moved that copy, and the consumed object was consumed again. A route that removed the headers, or replaced the message, left the object or the message in place, so it was consumed again. - The consumers now take the object name and the receipt handle before the exchange is routed, and pass them to a new `processCommit(Exchange, String)`. The delete and the move use the bucket of the endpoint. `processCommit(Exchange)` is kept for subclasses and deprecated, since the consumers no longer call it. - Same approach as CAMEL-27015 (#30168) for `aws2-s3`, `azure-storage-blob` and `aws2-sqs`. The two changes do not overlap. - The component pages say that the consumer deletes or moves what it consumed, whatever the route does with these headers. Tests: `GoogleCloudStorageConsumerDeleteMoveAfterReadTest` (3 of 6 fail before the fix), `MinioConsumerDeleteMoveAfterReadTest` (3 of 6), `MNSConsumerDeleteMessageTest` (2 of 4). The other tests are controls that pass before and after. All pass with the fix. The `FakeS3Server` of the minio tests now filters the listing by prefix, answers copies and records copies and deletes. Upgrade guide: new 4.24 entry "camel-google-storage, camel-minio, camel-alibaba-mns - the consumer deletes or moves what it consumed". _Claude Code on behalf of Federico Mariani_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
