Skip to content

GetObject result.ContentLength different from Response Content #2524

Closed
@gautampunhani

Description

@gautampunhani

Describe the bug

s3 Content Length and go-sdk's ContentLength is different. This causes our endpoints which were streaming data to fail. This has started happening after we did upgrades mentioned here #2370 go get -u github.com/aws/aws-sdk-go-v2/...
Screenshot 2024-03-01 at 6 30 42 PM

Expected Behavior

Content length should be same as received by the Http call in Debug logs

Current Behavior

Actual ContentLength : 25676
GetObject's result.ContentLength : 824635599248

Reproduction Steps

Please refer https://github.com/gautampunhani/aws-sdk-content-length-issue/tree/main , Which tries to access an AWS Open Data S3 file.

Possible Solution

No response

Additional Information/Context

No response

AWS Go SDK V2 Module Versions Used

Please refer here for versions used : https://github.com/gautampunhani/aws-sdk-content-length-issue/blob/main/go.mod

Compiler and Version used

go version go1.21.3

Operating System and version

darwin/amd64

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions