aws / aws/aws-sdk-java-v2

S3 client getObject() throws exception on 304 ("Not Modified")

Open
#428 4 comments 1 reaction 0 assignees View on GitHub
cross-sdk feature-request p2
Dominant language
Java
Stars
2.6k
Forks
1k
Avg merge
2d 9h
Merged PRs (30d)
51

Description

When getting an object from an S3 bucket with "ifNoneMatch", an exception is thrown if the eTag matches.

ResponseInputStream response = s3Client.getObject(getObjectRequest, StreamingResponseHandler.toInputStream());

## Expected Behavior
Not throwing an exception, instead only return the status code 304 and null InputStream when eTag matches.

See https://forums.aws.amazon.com/thread.jspa?threadID=77995&tstart=0

## Your Environment
* AWS Java SDK version used: 2.0.0-preview-8

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.