Skip to content

Commit 0203c3e

Browse files
Merge pull request #701 from aws/staging/fd170742-9fef-4b30-810c-ee148308313e
Pull request: release <- staging/fd170742-9fef-4b30-810c-ee148308313e
2 parents ab75b9c + 2418a09 commit 0203c3e

File tree

266 files changed

+338
-285
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

266 files changed

+338
-285
lines changed

.changes/2.10.34.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"version": "2.10.34",
3+
"date": "2019-12-12",
4+
"entries": [
5+
{
6+
"type": "bugfix",
7+
"category": "AWS SDK for Java v2",
8+
"description": "Fixing exception using `RequestBody.fromInputStream` on non-resettable `InputStreams` by making `reset` conditional on `markSupported`. See [#1544](https://github.com/aws/aws-sdk-java-v2/issues/1544) / [#1545](https://github.com/aws/aws-sdk-java-v2/issues/1545)"
9+
},
10+
{
11+
"type": "feature",
12+
"category": "Access Analyzer",
13+
"description": "This release includes improvements and fixes bugs for the IAM Access Analyzer feature."
14+
}
15+
]
16+
}

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
# __2.10.34__ __2019-12-12__
2+
## __AWS SDK for Java v2__
3+
- ### Bugfixes
4+
- Fixing exception using `RequestBody.fromInputStream` on non-resettable `InputStreams` by making `reset` conditional on `markSupported`. See [#1544](https://github.com/aws/aws-sdk-java-v2/issues/1544) / [#1545](https://github.com/aws/aws-sdk-java-v2/issues/1545)
5+
6+
## __Access Analyzer__
7+
- ### Features
8+
- This release includes improvements and fixes bugs for the IAM Access Analyzer feature.
9+
110
# __2.10.33__ __2019-12-11__
211
## __AWS SDK for Java v2__
312
- ### Features

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ To automatically manage module versions (currently all modules have the same ver
4848
<dependency>
4949
<groupId>software.amazon.awssdk</groupId>
5050
<artifactId>bom</artifactId>
51-
<version>2.10.33</version>
51+
<version>2.10.34</version>
5252
<type>pom</type>
5353
<scope>import</scope>
5454
</dependency>
@@ -82,12 +82,12 @@ Alternatively you can add dependencies for the specific services you use only:
8282
<dependency>
8383
<groupId>software.amazon.awssdk</groupId>
8484
<artifactId>ec2</artifactId>
85-
<version>2.10.33</version>
85+
<version>2.10.34</version>
8686
</dependency>
8787
<dependency>
8888
<groupId>software.amazon.awssdk</groupId>
8989
<artifactId>s3</artifactId>
90-
<version>2.10.33</version>
90+
<version>2.10.34</version>
9191
</dependency>
9292
```
9393

@@ -99,7 +99,7 @@ You can import the whole SDK into your project (includes *ALL* services). Please
9999
<dependency>
100100
<groupId>software.amazon.awssdk</groupId>
101101
<artifactId>aws-sdk-java</artifactId>
102-
<version>2.10.33</version>
102+
<version>2.10.34</version>
103103
</dependency>
104104
```
105105

aws-sdk-java/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>software.amazon.awssdk</groupId>
66
<artifactId>aws-sdk-java-pom</artifactId>
7-
<version>2.10.33</version>
7+
<version>2.10.34</version>
88
<relativePath>../pom.xml</relativePath>
99
</parent>
1010
<artifactId>aws-sdk-java</artifactId>

bom-internal/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>aws-sdk-java-pom</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

bom/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>software.amazon.awssdk</groupId>
66
<artifactId>aws-sdk-java-pom</artifactId>
7-
<version>2.10.33</version>
7+
<version>2.10.34</version>
88
<relativePath>../pom.xml</relativePath>
99
</parent>
1010
<artifactId>bom</artifactId>

bundle/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<groupId>software.amazon.awssdk</groupId>
2323
<artifactId>aws-sdk-java-pom</artifactId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626
<artifactId>bundle</artifactId>
2727
<packaging>jar</packaging>

codegen-lite-maven-plugin/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>software.amazon.awssdk</groupId>
99
<artifactId>aws-sdk-java-pom</artifactId>
10-
<version>2.10.33</version>
10+
<version>2.10.34</version>
1111
<relativePath>../pom.xml</relativePath>
1212
</parent>
1313
<artifactId>codegen-lite-maven-plugin</artifactId>

codegen-lite/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<parent>
77
<groupId>software.amazon.awssdk</groupId>
88
<artifactId>aws-sdk-java-pom</artifactId>
9-
<version>2.10.33</version>
9+
<version>2.10.34</version>
1010
</parent>
1111
<artifactId>codegen-lite</artifactId>
1212
<name>AWS Java SDK :: Code Generator Lite</name>

codegen-maven-plugin/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>software.amazon.awssdk</groupId>
2424
<artifactId>aws-sdk-java-pom</artifactId>
25-
<version>2.10.33</version>
25+
<version>2.10.34</version>
2626
<relativePath>../pom.xml</relativePath>
2727
</parent>
2828
<artifactId>codegen-maven-plugin</artifactId>

codegen/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<groupId>software.amazon.awssdk</groupId>
2323
<artifactId>aws-sdk-java-pom</artifactId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626
<artifactId>codegen</artifactId>
2727
<name>AWS Java SDK :: Code Generator</name>

core/annotations/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>core</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/arns/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>core</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.10.33</version>
23+
<version>2.10.34</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626

core/auth/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>software.amazon.awssdk</groupId>
99
<artifactId>core</artifactId>
10-
<version>2.10.33</version>
10+
<version>2.10.34</version>
1111
</parent>
1212

1313
<artifactId>auth</artifactId>

core/aws-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>software.amazon.awssdk</groupId>
99
<artifactId>core</artifactId>
10-
<version>2.10.33</version>
10+
<version>2.10.34</version>
1111
</parent>
1212

1313
<artifactId>aws-core</artifactId>

core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<artifactId>aws-sdk-java-pom</artifactId>
2323
<groupId>software.amazon.awssdk</groupId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626

2727
<artifactId>core</artifactId>

core/profiles/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>software.amazon.awssdk</groupId>
2424
<artifactId>core</artifactId>
25-
<version>2.10.33</version>
25+
<version>2.10.34</version>
2626
</parent>
2727

2828
<artifactId>profiles</artifactId>

core/protocols/aws-cbor-protocol/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/aws-ion-protocol/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/aws-json-protocol/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/aws-query-protocol/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/aws-xml-protocol/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>core</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/protocols/protocol-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>protocols</artifactId>
77
<groupId>software.amazon.awssdk</groupId>
8-
<version>2.10.33</version>
8+
<version>2.10.34</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

core/regions/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>software.amazon.awssdk</groupId>
2424
<artifactId>core</artifactId>
25-
<version>2.10.33</version>
25+
<version>2.10.34</version>
2626
</parent>
2727

2828
<artifactId>regions</artifactId>

core/sdk-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<groupId>software.amazon.awssdk</groupId>
2323
<artifactId>core</artifactId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626
<artifactId>sdk-core</artifactId>
2727
<name>AWS Java SDK :: SDK Core</name>

core/sdk-core/src/main/java/software/amazon/awssdk/core/sync/RequestBody.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,9 @@ public static RequestBody fromInputStream(InputStream inputStream, long contentL
119119
IoUtils.markStreamWithMaxReadLimit(inputStream);
120120
InputStream nonCloseable = nonCloseableInputStream(inputStream);
121121
return fromContentProvider(() -> {
122-
invokeSafely(nonCloseable::reset);
122+
if (nonCloseable.markSupported()) {
123+
invokeSafely(nonCloseable::reset);
124+
}
123125
return nonCloseable;
124126
}, contentLength, Mimetype.MIMETYPE_OCTET_STREAM);
125127
}

core/sdk-core/src/test/java/software/amazon/awssdk/core/sync/RequestBodyTest.java

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,28 @@
1919

2020
import com.google.common.jimfs.Configuration;
2121
import com.google.common.jimfs.Jimfs;
22+
import java.io.File;
23+
import java.io.FileInputStream;
24+
import java.io.FileWriter;
2225
import java.io.IOException;
26+
import java.io.InputStream;
2327
import java.nio.ByteBuffer;
2428
import java.nio.file.FileSystem;
2529
import java.nio.file.Files;
2630
import java.nio.file.Path;
31+
import org.junit.Rule;
2732
import org.junit.Test;
33+
import org.junit.rules.TemporaryFolder;
2834
import software.amazon.awssdk.core.internal.util.Mimetype;
2935
import software.amazon.awssdk.utils.IoUtils;
3036
import software.amazon.awssdk.utils.StringInputStream;
3137

3238

3339
public class RequestBodyTest {
3440

41+
@Rule
42+
public TemporaryFolder folder = new TemporaryFolder();
43+
3544
@Test
3645
public void stringConstructorUsesUTF8ByteLength() {
3746
// U+03A9 U+03C9
@@ -63,6 +72,20 @@ public void streamConstructorHasCorrectContentType() {
6372
IoUtils.closeQuietly(inputStream, null);
6473
}
6574

75+
76+
@Test
77+
public void nonMarkSupportedInputStreamContentType() throws IOException {
78+
File file = folder.newFile();
79+
try (FileWriter writer = new FileWriter(file)) {
80+
writer.write("hello world");
81+
}
82+
InputStream inputStream = Files.newInputStream(file.toPath());
83+
RequestBody requestBody = RequestBody.fromInputStream(inputStream, 11);
84+
assertThat(requestBody.contentType()).isEqualTo(Mimetype.MIMETYPE_OCTET_STREAM);
85+
assertThat(requestBody.contentStreamProvider().newStream()).isNotNull();
86+
IoUtils.closeQuietly(inputStream, null);
87+
}
88+
6689
@Test
6790
public void bytesArrayConstructorHasCorrectContentType() {
6891
RequestBody requestBody = RequestBody.fromBytes("hello world".getBytes());

http-client-spi/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<artifactId>aws-sdk-java-pom</artifactId>
2424
<groupId>software.amazon.awssdk</groupId>
25-
<version>2.10.33</version>
25+
<version>2.10.34</version>
2626
</parent>
2727
<artifactId>http-client-spi</artifactId>
2828
<name>AWS Java SDK :: HTTP Client Interface</name>

http-clients/apache-client/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<artifactId>http-clients</artifactId>
2323
<groupId>software.amazon.awssdk</groupId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626

2727
<artifactId>apache-client</artifactId>

http-clients/netty-nio-client/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>http-clients</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.10.33</version>
23+
<version>2.10.34</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626

http-clients/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<parent>
2222
<artifactId>aws-sdk-java-pom</artifactId>
2323
<groupId>software.amazon.awssdk</groupId>
24-
<version>2.10.33</version>
24+
<version>2.10.34</version>
2525
</parent>
2626
<modelVersion>4.0.0</modelVersion>
2727

http-clients/url-connection-client/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>http-clients</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.10.33</version>
23+
<version>2.10.34</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<modelVersion>4.0.0</modelVersion>
2121
<groupId>software.amazon.awssdk</groupId>
2222
<artifactId>aws-sdk-java-pom</artifactId>
23-
<version>2.10.33</version>
23+
<version>2.10.34</version>
2424
<packaging>pom</packaging>
2525
<name>AWS Java SDK :: Parent</name>
2626
<description>The Amazon Web Services SDK for Java provides Java APIs

release-scripts/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>software.amazon.awssdk</groupId>
2424
<artifactId>aws-sdk-java-pom</artifactId>
25-
<version>2.10.33</version>
25+
<version>2.10.34</version>
2626
<relativePath>../pom.xml</relativePath>
2727
</parent>
2828
<artifactId>release-scripts</artifactId>

0 commit comments

Comments
 (0)