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.ChangeMessageVisibilityBatch fails when entries' VisibilityTimeout is zero #2250

Closed
eraserhd opened this issue Aug 21, 2023 · 9 comments · Fixed by #2767
Closed

sqs.ChangeMessageVisibilityBatch fails when entries' VisibilityTimeout is zero #2250

eraserhd opened this issue Aug 21, 2023 · 9 comments · Fixed by #2767
Assignees
Labels
bug This issue is a bug. p1 This is a high priority issue queued This issues is on the AWS team's backlog service-api This issue is due to a problem in a service API, not the SDK implementation.

Comments

@eraserhd
Copy link

Describe the bug

According to https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_ChangeMessageVisibility.html , the minimum value is 0. Elsewhere, the documentation describes using zero to make the entry immediately visible. This does not work with the Go API.

Expected Behavior

A successful response.

Current Behavior

The API responds with:

{
	"Failed": [
		{
			"Message": "The request must contain the parameter ChangeMessageVisibilityBatchRequestEntry.1.VisibilityTimeout.",
			"Id": "93486601",
			"Code": "MissingParameter",
			"SenderFault": true
		}
	]
}

... suggesting that the API is not serializing the field because of its zero-value.

Note that the documentation does not say this is a required field, but apparently it is, so perhaps some metadata somewhere is messed up?

Reproduction Steps

Call ChangeMessageVisibilityBatch with a single entry with VisibilityTimeout of 0.

If you change VisibilityTimeout to 1, the call succeeds.

Possible Solution

Marking the field as required so it is serialized, or marking it as required to serialize?

Additional Information/Context

No response

AWS Go SDK V2 Module Versions Used

	github.com/aws/aws-sdk-go-v2/config v1.17.1
	github.com/aws/aws-sdk-go-v2/service/secretsmanager v1.15.18
	github.com/aws/aws-sdk-go-v2/service/sqs v1.20.8
	github.com/aws/aws-sdk-go-v2 v1.17.8 // indirect
	github.com/aws/aws-sdk-go-v2/credentials v1.12.14 // indirect
	github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.12.12 // indirect
	github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.32 // indirect
	github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.4.26 // indirect
	github.com/aws/aws-sdk-go-v2/internal/ini v1.3.19 // indirect
	github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.9.12 // indirect
	github.com/aws/aws-sdk-go-v2/service/sso v1.11.17 // indirect
	github.com/aws/aws-sdk-go-v2/service/sts v1.16.13 // indirect

Compiler and Version used

Go 1.21.0

Operating System and version

Linux debian:buster

@eraserhd eraserhd added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Aug 21, 2023
@RanVaknin
Copy link
Contributor

Hi @eraserhd ,

Can you please pull the latest version of the SQS client? We are on Version: v1.44.327 .
Im pretty sure this was fixed a long time ago.

Thanks,
Ran~

@RanVaknin RanVaknin self-assigned this Aug 21, 2023
@RanVaknin RanVaknin added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. p2 This is a standard priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Aug 21, 2023
@eraserhd
Copy link
Author

That's aws-go-sdk, not aws-go-sdk-v2; however, I updated to these (most recent) versions, and still have the problem:

        github.com/aws/aws-sdk-go-v2/config v1.18.36
        github.com/aws/aws-sdk-go-v2/service/secretsmanager v1.21.3
        github.com/aws/aws-sdk-go-v2/service/sqs v1.24.5
        github.com/aws/aws-sdk-go-v2 v1.21.0 // indirect
        github.com/aws/aws-sdk-go-v2/credentials v1.13.35 // indirect
        github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.13.11 // indirect
        github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.41 // indirect
        github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.4.35 // indirect
        github.com/aws/aws-sdk-go-v2/internal/ini v1.3.42 // indirect
        github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.9.35 // indirect
        github.com/aws/aws-sdk-go-v2/service/sso v1.13.5 // indirect
        github.com/aws/aws-sdk-go-v2/service/ssooidc v1.15.5 // indirect
        github.com/aws/aws-sdk-go-v2/service/sts v1.21.5 // indirect
        github.com/aws/smithy-go v1.14.2 // indirect

@lucix-aws lucix-aws removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. label Aug 23, 2023
@lucix-aws
Copy link
Contributor

This is another symptom of the larger problem described in #2162.

I've added this instance to the list of known offenders there. Will close this as duplicate

@lucix-aws lucix-aws added duplicate This issue is a duplicate. and removed p2 This is a standard priority issue labels Aug 23, 2023
@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

@RanVaknin
Copy link
Contributor

sorry. I thought this was fixed.
We are tracking this in the cross-sdk repo: aws/aws-sdk#527

@jfrconley
Copy link

This is still broken as of v1.34.5

@lucix-aws lucix-aws assigned lucix-aws and unassigned RanVaknin Aug 30, 2024
@lucix-aws lucix-aws added service-api This issue is due to a problem in a service API, not the SDK implementation. p1 This is a high priority issue queued This issues is on the AWS team's backlog and removed duplicate This issue is a duplicate. labels Aug 30, 2024
@lucix-aws lucix-aws reopened this Aug 30, 2024
@lucix-aws
Copy link
Contributor

@lucix-aws
Copy link
Contributor

@eraserhd @keenangraham

Copy link

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.

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. p1 This is a high priority issue queued This issues is on the AWS team's backlog service-api This issue is due to a problem in a service API, not the SDK implementation.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants