Skip to content

Commit a92f967

Browse files
authored
Merge pull request #853 from aws/staging/fc650e8a-ed4f-453a-b1b1-4619e6bbd825
Pull request: release <- staging/fc650e8a-ed4f-453a-b1b1-4619e6bbd825
2 parents 9a86128 + 6fcfbd5 commit a92f967

File tree

289 files changed

+756
-353
lines changed

Some content is hidden

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

289 files changed

+756
-353
lines changed

.changes/2.13.22.json

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"version": "2.13.22",
3+
"date": "2020-05-21",
4+
"entries": [
5+
{
6+
"type": "bugfix",
7+
"category": "AWS SDK for Java v2",
8+
"description": "Fixed an issue where a service returning an unknown response event type would cause a failure."
9+
},
10+
{
11+
"type": "feature",
12+
"category": "AWS SDK for Java v2",
13+
"description": "Updated service endpoint metadata."
14+
},
15+
{
16+
"type": "feature",
17+
"category": "Synthetics",
18+
"description": "AWS CloudWatch Synthetics now supports configuration of allocated memory for a canary."
19+
},
20+
{
21+
"type": "feature",
22+
"category": "AWS CodeBuild",
23+
"description": "CodeBuild adds support for tagging with report groups"
24+
},
25+
{
26+
"type": "feature",
27+
"category": "Amazon Elastic Compute Cloud",
28+
"description": "From this release onwards ProvisionByoipCidr publicly supports IPv6. Updated ProvisionByoipCidr API to support tags for public IPv4 and IPv6 pools. Added NetworkBorderGroup to the DescribePublicIpv4Pools response."
29+
},
30+
{
31+
"type": "feature",
32+
"category": "Amazon Simple Storage Service",
33+
"description": "Deprecates unusable input members bound to Content-MD5 header. Updates example and documentation."
34+
}
35+
]
36+
}

CHANGELOG.md

+24
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
# __2.13.22__ __2020-05-21__
2+
## __AWS CodeBuild__
3+
- ### Features
4+
- CodeBuild adds support for tagging with report groups
5+
6+
## __AWS SDK for Java v2__
7+
- ### Features
8+
- Updated service endpoint metadata.
9+
10+
- ### Bugfixes
11+
- Fixed an issue where a service returning an unknown response event type would cause a failure.
12+
13+
## __Amazon Elastic Compute Cloud__
14+
- ### Features
15+
- From this release onwards ProvisionByoipCidr publicly supports IPv6. Updated ProvisionByoipCidr API to support tags for public IPv4 and IPv6 pools. Added NetworkBorderGroup to the DescribePublicIpv4Pools response.
16+
17+
## __Amazon Simple Storage Service__
18+
- ### Features
19+
- Deprecates unusable input members bound to Content-MD5 header. Updates example and documentation.
20+
21+
## __Synthetics__
22+
- ### Features
23+
- AWS CloudWatch Synthetics now supports configuration of allocated memory for a canary.
24+
125
# __2.13.21__ __2020-05-20__
226
## __AWS App Mesh__
327
- ### Features

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ To automatically manage module versions (currently all modules have the same ver
4949
<dependency>
5050
<groupId>software.amazon.awssdk</groupId>
5151
<artifactId>bom</artifactId>
52-
<version>2.13.21</version>
52+
<version>2.13.22</version>
5353
<type>pom</type>
5454
<scope>import</scope>
5555
</dependency>
@@ -83,12 +83,12 @@ Alternatively you can add dependencies for the specific services you use only:
8383
<dependency>
8484
<groupId>software.amazon.awssdk</groupId>
8585
<artifactId>ec2</artifactId>
86-
<version>2.13.21</version>
86+
<version>2.13.22</version>
8787
</dependency>
8888
<dependency>
8989
<groupId>software.amazon.awssdk</groupId>
9090
<artifactId>s3</artifactId>
91-
<version>2.13.21</version>
91+
<version>2.13.22</version>
9292
</dependency>
9393
```
9494

@@ -100,7 +100,7 @@ You can import the whole SDK into your project (includes *ALL* services). Please
100100
<dependency>
101101
<groupId>software.amazon.awssdk</groupId>
102102
<artifactId>aws-sdk-java</artifactId>
103-
<version>2.13.21</version>
103+
<version>2.13.22</version>
104104
</dependency>
105105
```
106106

archetypes/archetype-lambda/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>archetypes</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.13.21</version>
23+
<version>2.13.22</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626
<artifactId>archetype-lambda</artifactId>

archetypes/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>aws-sdk-java-pom</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.13.21</version>
23+
<version>2.13.22</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626
<artifactId>archetypes</artifactId>

aws-sdk-java/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<parent>
1818
<groupId>software.amazon.awssdk</groupId>
1919
<artifactId>aws-sdk-java-pom</artifactId>
20-
<version>2.13.21</version>
20+
<version>2.13.22</version>
2121
<relativePath>../pom.xml</relativePath>
2222
</parent>
2323
<artifactId>aws-sdk-java</artifactId>

bom-internal/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<parent>
2121
<artifactId>aws-sdk-java-pom</artifactId>
2222
<groupId>software.amazon.awssdk</groupId>
23-
<version>2.13.21</version>
23+
<version>2.13.22</version>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>
2626

bom/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<parent>
1818
<groupId>software.amazon.awssdk</groupId>
1919
<artifactId>aws-sdk-java-pom</artifactId>
20-
<version>2.13.21</version>
20+
<version>2.13.22</version>
2121
<relativePath>../pom.xml</relativePath>
2222
</parent>
2323
<artifactId>bom</artifactId>

bundle/pom.xml

+1-1
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.13.21</version>
24+
<version>2.13.22</version>
2525
</parent>
2626
<artifactId>bundle</artifactId>
2727
<packaging>jar</packaging>

codegen-lite-maven-plugin/pom.xml

+1-1
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.13.21</version>
25+
<version>2.13.22</version>
2626
<relativePath>../pom.xml</relativePath>
2727
</parent>
2828
<artifactId>codegen-lite-maven-plugin</artifactId>

codegen-lite/pom.xml

+1-1
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.13.21</version>
24+
<version>2.13.22</version>
2525
</parent>
2626
<artifactId>codegen-lite</artifactId>
2727
<name>AWS Java SDK :: Code Generator Lite</name>

codegen-maven-plugin/pom.xml

+1-1
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.13.21</version>
25+
<version>2.13.22</version>
2626
<relativePath>../pom.xml</relativePath>
2727
</parent>
2828
<artifactId>codegen-maven-plugin</artifactId>

codegen/pom.xml

+1-1
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.13.21</version>
24+
<version>2.13.22</version>
2525
</parent>
2626
<artifactId>codegen</artifactId>
2727
<name>AWS Java SDK :: Code Generator</name>

codegen/src/main/java/software/amazon/awssdk/codegen/docs/OperationDocProvider.java

+6-1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
import software.amazon.awssdk.codegen.model.intermediate.IntermediateModel;
2626
import software.amazon.awssdk.codegen.model.intermediate.OperationModel;
2727
import software.amazon.awssdk.codegen.model.intermediate.ShapeModel;
28+
import software.amazon.awssdk.codegen.model.service.PaginatorDefinition;
2829
import software.amazon.awssdk.utils.Pair;
2930
import software.amazon.awssdk.utils.StringUtils;
3031

@@ -58,7 +59,7 @@ abstract class OperationDocProvider {
5859
this.model = model;
5960
this.opModel = opModel;
6061
this.config = config;
61-
this.paginationDocs = new PaginationDocs(model, opModel);
62+
this.paginationDocs = new PaginationDocs(model, opModel, getPaginatorDefinition());
6263
}
6364

6465
/**
@@ -180,6 +181,10 @@ final void emitRequestParm(DocumentationBuilder docBuilder) {
180181
}
181182
}
182183

184+
private PaginatorDefinition getPaginatorDefinition() {
185+
return model.getPaginators().get(opModel.getOperationName());
186+
}
187+
183188
/**
184189
* @return The interface name of the client. Will differ per {@link ClientType}.
185190
*/

codegen/src/main/java/software/amazon/awssdk/codegen/docs/PaginationDocs.java

+19-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import org.reactivestreams.Subscription;
2424
import software.amazon.awssdk.codegen.model.intermediate.IntermediateModel;
2525
import software.amazon.awssdk.codegen.model.intermediate.OperationModel;
26+
import software.amazon.awssdk.codegen.model.service.PaginatorDefinition;
2627
import software.amazon.awssdk.codegen.poet.PoetExtensions;
2728
import software.amazon.awssdk.codegen.utils.PaginatorUtils;
2829
import software.amazon.awssdk.utils.async.SequentialSubscriber;
@@ -33,10 +34,13 @@ public class PaginationDocs {
3334

3435
private final OperationModel operationModel;
3536
private final PoetExtensions poetExtensions;
37+
private final PaginatorDefinition paginatorDefinition;
3638

37-
public PaginationDocs(IntermediateModel intermediateModel, OperationModel operationModel) {
39+
public PaginationDocs(IntermediateModel intermediateModel, OperationModel operationModel,
40+
PaginatorDefinition paginatorDefinition) {
3841
this.operationModel = operationModel;
3942
this.poetExtensions = new PoetExtensions(intermediateModel);
43+
this.paginatorDefinition = paginatorDefinition;
4044
}
4145

4246
/**
@@ -149,6 +153,7 @@ private String getSyncCodeSnippets() {
149153
.add(callOperationOnClient)
150154
.addStatement("responses.iterator().forEachRemaining(....)")
151155
.build()))
156+
.add(noteAboutLimitConfigurationMethod())
152157
.add(noteAboutSyncNonPaginatedMethod())
153158
.build()
154159
.toString();
@@ -186,6 +191,7 @@ private String getAsyncCodeSnippets() {
186191
.build()))
187192
.add("As the response is a publisher, it can work well with third party reactive streams implementations "
188193
+ "like RxJava2.")
194+
.add(noteAboutLimitConfigurationMethod())
189195
.add(noteAboutSyncNonPaginatedMethod())
190196
.build()
191197
.toString();
@@ -238,6 +244,18 @@ private ClassName asyncPaginatedResponseType() {
238244
return poetExtensions.getResponseClassForPaginatedAsyncOperation(operationModel.getOperationName());
239245
}
240246

247+
private String getPaginatorLimitKeyName() {
248+
return paginatorDefinition != null ? paginatorDefinition.getLimitKey() : "";
249+
}
250+
251+
private CodeBlock noteAboutLimitConfigurationMethod() {
252+
return CodeBlock.builder()
253+
.add("\n<p><b>Please notice that the configuration of $L won't limit the number of results "
254+
+ "you get with the paginator. It only limits the number of results in each page.</b></p>",
255+
getPaginatorLimitKeyName())
256+
.build();
257+
}
258+
241259
private CodeBlock noteAboutSyncNonPaginatedMethod() {
242260
return CodeBlock.builder()
243261
.add("\n<p><b>Note: If you prefer to have control on service calls, use the {@link #$L($T)} operation."

codegen/src/main/java/software/amazon/awssdk/codegen/poet/client/specs/JsonProtocolSpec.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
import software.amazon.awssdk.codegen.model.intermediate.ShapeModel;
4040
import software.amazon.awssdk.codegen.poet.PoetExtensions;
4141
import software.amazon.awssdk.codegen.poet.eventstream.EventStreamUtils;
42+
import software.amazon.awssdk.core.SdkPojoBuilder;
4243
import software.amazon.awssdk.core.SdkResponse;
4344
import software.amazon.awssdk.core.async.AsyncRequestBody;
4445
import software.amazon.awssdk.core.client.handler.AttachHttpMetadataResponseHandler;
@@ -420,8 +421,8 @@ private void responseHandlersForEventStreaming(OperationModel opModel, TypeName
420421
EventStreamUtils.getEventMembers(eventStream)
421422
.forEach(m -> builder.add(".putSdkPojoSupplier(\"$L\", $T::builder)\n",
422423
m.getC2jName(), poetExtensions.getModelClass(m.getShape().getC2jName())));
423-
builder.add(".defaultSdkPojoSupplier(() -> $T.UNKNOWN)\n"
424-
+ ".build());\n", eventStreamBaseClass);
424+
builder.add(".defaultSdkPojoSupplier(() -> new $T($T.UNKNOWN))\n"
425+
+ ".build());\n", SdkPojoBuilder.class, eventStreamBaseClass);
425426
}
426427

427428
private String protocolFactoryLiteral(IntermediateModel model, OperationModel opModel) {

codegen/src/main/java/software/amazon/awssdk/codegen/poet/paginators/PaginatorsClassSpec.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public PaginatorsClassSpec(IntermediateModel model, String c2jOperationName, Pag
6363
this.poetExtensions = new PoetExtensions(model);
6464
this.typeProvider = new TypeProvider(model);
6565
this.operationModel = model.getOperation(c2jOperationName);
66-
this.paginationDocs = new PaginationDocs(model, operationModel);
66+
this.paginationDocs = new PaginationDocs(model, operationModel, paginatorDefinition);
6767
}
6868

6969
/**

codegen/src/test/resources/software/amazon/awssdk/codegen/poet/client/test-async-client-class.java

+13-2
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
import software.amazon.awssdk.awscore.eventstream.RestEventStreamAsyncResponseTransformer;
2323
import software.amazon.awssdk.awscore.exception.AwsServiceException;
2424
import software.amazon.awssdk.core.ApiName;
25+
import software.amazon.awssdk.core.SdkPojoBuilder;
2526
import software.amazon.awssdk.core.SdkResponse;
2627
import software.amazon.awssdk.core.async.AsyncRequestBody;
2728
import software.amazon.awssdk.core.async.AsyncResponseTransformer;
@@ -259,7 +260,8 @@ public CompletableFuture<Void> eventStreamOperation(EventStreamOperationRequest
259260
HttpResponseHandler<? extends EventStream> eventResponseHandler = protocolFactory.createResponseHandler(
260261
JsonOperationMetadata.builder().isPayloadJson(true).hasStreamingSuccessResponse(false).build(),
261262
EventStreamTaggedUnionPojoSupplier.builder().putSdkPojoSupplier("EventOne", EventOne::builder)
262-
.putSdkPojoSupplier("event-two", EventTwo::builder).defaultSdkPojoSupplier(() -> EventStream.UNKNOWN)
263+
.putSdkPojoSupplier("event-two", EventTwo::builder)
264+
.defaultSdkPojoSupplier(() -> new SdkPojoBuilder(EventStream.UNKNOWN))
263265
.build());
264266

265267
HttpResponseHandler<AwsServiceException> errorResponseHandler = createErrorResponseHandler(protocolFactory,
@@ -397,7 +399,8 @@ public CompletableFuture<Void> eventStreamOperationWithOnlyOutput(
397399
HttpResponseHandler<? extends EventStream> eventResponseHandler = protocolFactory.createResponseHandler(
398400
JsonOperationMetadata.builder().isPayloadJson(true).hasStreamingSuccessResponse(false).build(),
399401
EventStreamTaggedUnionPojoSupplier.builder().putSdkPojoSupplier("EventOne", EventOne::builder)
400-
.putSdkPojoSupplier("event-two", EventTwo::builder).defaultSdkPojoSupplier(() -> EventStream.UNKNOWN)
402+
.putSdkPojoSupplier("event-two", EventTwo::builder)
403+
.defaultSdkPojoSupplier(() -> new SdkPojoBuilder(EventStream.UNKNOWN))
401404
.build());
402405

403406
HttpResponseHandler<AwsServiceException> errorResponseHandler = createErrorResponseHandler(protocolFactory,
@@ -577,6 +580,10 @@ public CompletableFuture<PaginatedOperationWithResultKeyResponse> paginatedOpera
577580
*
578581
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
579582
* <p>
583+
* <b>Please notice that the configuration of MaxResults won't limit the number of results you get with the
584+
* paginator. It only limits the number of results in each page.</b>
585+
* </p>
586+
* <p>
580587
* <b>Note: If you prefer to have control on service calls, use the
581588
* {@link #paginatedOperationWithResultKey(software.amazon.awssdk.services.json.model.PaginatedOperationWithResultKeyRequest)}
582589
* operation.</b>
@@ -695,6 +702,10 @@ public CompletableFuture<PaginatedOperationWithoutResultKeyResponse> paginatedOp
695702
*
696703
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
697704
* <p>
705+
* <b>Please notice that the configuration of MaxResults won't limit the number of results you get with the
706+
* paginator. It only limits the number of results in each page.</b>
707+
* </p>
708+
* <p>
698709
* <b>Note: If you prefer to have control on service calls, use the
699710
* {@link #paginatedOperationWithoutResultKey(software.amazon.awssdk.services.json.model.PaginatedOperationWithoutResultKeyRequest)}
700711
* operation.</b>

0 commit comments

Comments
 (0)