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

SQS DeleteMessageBatchResponse hasFailed method unexpected response #4713

Closed
hsulich opened this issue Nov 21, 2023 · 8 comments
Closed

SQS DeleteMessageBatchResponse hasFailed method unexpected response #4713

hsulich opened this issue Nov 21, 2023 · 8 comments
Assignees
Labels
bug This issue is a bug. closed-for-staleness p1 This is a high priority issue

Comments

@hsulich
Copy link

hsulich commented Nov 21, 2023

Describe the bug

After upgrading the aws sdk version from 2.21.16 to 2.21.23, the behavior of the SQS DeleteMessageBatchResponse hasFailed method has changed. The version upgrade includes changes to the SQS sdk so it appears to be related.

Previous behavior:
If there were no messages in the batch that were failed to be deleted, hasFailed returned false.

Current behvaior:
For the same scenario hasFailed now returns true, even though no messages in the batch were failed to be deleted. Sample log from our application that shows the Failed list is empty - this log is written when hasFailed returns true:

Failed to delete processed messages: DeleteMessageBatchResponse(Successful=[DeleteMessageBatchResultEntry(Id=3bd265b6-0f3a-47f5-93da-e4262e76469d)], Failed=[])

The javadoc confuses me because it says the following:

This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property)

However, it seems that before this sdk upgrade, we did not need to check if the list for the Failed property was non-empty.

Expected Behavior

hasFailed should return false if there are no messages in the batch that were failed to be deleted.

Current Behavior

hasFailed now returns true if there are no messages in the batch that were failed to be deleted.

Reproduction Steps

Perform DeleteMessageBatch request and call the hasFailed method for the resulting DeleteMessageBatchResponse.

Possible Solution

No response

Additional Information/Context

No response

AWS Java SDK version used

2.21.23

JDK version used

17

Operating System and version

debian11

@hsulich hsulich added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Nov 21, 2023
@debora-ito
Copy link
Member

@hsulich we are aware of the issue. You're correct, seems like it was an effect of the SQS protocol change.

We are actively working with the SQS team, discussing possible solutions.

@debora-ito debora-ito added p1 This is a high priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Nov 21, 2023
@debora-ito debora-ito self-assigned this Nov 21, 2023
@jppavez
Copy link

jppavez commented Nov 22, 2023

Looks like SendMessageBatchResponse is also impacted. Also getting true when the list of .failed() is empty.

@debora-ito
Copy link
Member

@hsulich @jppavez

a service-side fix is rolling out now. It should be fixed in us-west-2, which region are you all using?

@hsulich
Copy link
Author

hsulich commented Nov 22, 2023

Glad to hear that! I'm using us-east-2

@debora-ito
Copy link
Member

Just tested locally, the fix didn't hit us-east-2 yet.

I don't have an estimate time for the fix, but the deploy is ongoing. We appreciate your patience with this.

@debora-ito debora-ito pinned this issue Nov 22, 2023
@ghost
Copy link

ghost commented Nov 24, 2023

I am using eu-central-1. Do you know when the fix is planned to be rolled out in Europe?

@debora-ito
Copy link
Member

@hsulich @frederikmartin1337 the fix is now available in all regions. Let us know if you still see the issue.

@debora-ito debora-ito added the closing-soon This issue will close in 4 days unless further comments are made. label Nov 29, 2023
@github-actions github-actions bot added closed-for-staleness and removed closing-soon This issue will close in 4 days unless further comments are made. labels Dec 1, 2023
@github-actions github-actions bot closed this as completed Dec 1, 2023
@mihalyr
Copy link

mihalyr commented Dec 8, 2023

Facing a very similar issue with SendMessageBatchResponse, it doesn't seem to be server side issue, I am testing locally and the new SDK fails my integ tests #4759

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. closed-for-staleness p1 This is a high priority issue
Projects
None yet
Development

No branches or pull requests

4 participants