Skip to content

Commit 2b474b9

Browse files
authored
Merge pull request #10964 from aws/bump/1.69.0
chore(release): 1.69.0
2 parents a6a3f46 + 426b7db commit 2b474b9

File tree

202 files changed

+3739
-3913
lines changed

Some content is hidden

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

202 files changed

+3739
-3913
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Automatically approve PRs that merge master forward to v2-main
2+
#
3+
# Only does approvals! mergify takes care of the actual merge.
4+
name: Auto-approve forward merges onto v2-main
5+
on:
6+
pull_request:
7+
types:
8+
- labeled
9+
- opened
10+
- ready_for_review
11+
- reopened
12+
- synchronize
13+
- unlabeled
14+
- unlocked
15+
16+
jobs:
17+
approve:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: hmarr/auto-approve-action@v2.0.0
21+
if: >
22+
github.event.pull_request.user.login == 'aws-cdk-automation'
23+
&& github.event.pull_request.base.ref == 'v2-main'
24+
&& contains(github.event.pull_request.labels.*.name, 'pr/forward-merge')
25+
with:
26+
github-token: "${{ secrets.GITHUB_TOKEN }}"

.mergify.yml

+17
Original file line numberDiff line numberDiff line change
@@ -119,3 +119,20 @@ pull_request_rules:
119119
- "#changes-requested-reviews-by=0"
120120
- status-success~=AWS CodeBuild us-east-1
121121
- status-success=validate-pr
122+
- name: automatic merge of v2 forward merges
123+
actions:
124+
comment:
125+
message: Forward merge successful!
126+
merge:
127+
method: merge
128+
strict: smart+fasttrack
129+
strict_method: merge
130+
commit_message: title+body
131+
conditions:
132+
- label~=forward-merge
133+
- -label~=(blocked|do-not-merge)
134+
- -merged
135+
- -closed
136+
- author~=aws-cdk-automation
137+
- "#approved-reviews-by>=1"
138+
- status-success~=AWS CodeBuild us-east-1

CHANGELOG.md

+17
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,23 @@
22

33
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
44

5+
## [1.69.0](https://github.com/aws/aws-cdk/compare/v1.68.0...v1.69.0) (2020-10-19)
6+
7+
8+
### Features
9+
10+
* **apigatewayv2:** configure description for HttpApi ([#10863](https://github.com/aws/aws-cdk/issues/10863)) ([895372f](https://github.com/aws/aws-cdk/commit/895372fc8b027bd12d64450c429c04d8efdd27f4))
11+
* **pipelines:** temporarily disable self-mutation ([#10466](https://github.com/aws/aws-cdk/issues/10466)) ([8ffabb4](https://github.com/aws/aws-cdk/commit/8ffabb4325d2853f8650f991706eccfe233b2c74))
12+
13+
14+
### Bug Fixes
15+
16+
* **apigateway:** cannot configure stage for SpecRestApi ([#10749](https://github.com/aws/aws-cdk/issues/10749)) ([62a2286](https://github.com/aws/aws-cdk/commit/62a2286f6dc46059160daa3c7466e712dad9f136)), closes [#10300](https://github.com/aws/aws-cdk/issues/10300)
17+
* **apigateway:** lambda integration does not recognize allowTestInvoke ([#10828](https://github.com/aws/aws-cdk/issues/10828)) ([650c23f](https://github.com/aws/aws-cdk/commit/650c23f1fe9e87a7b1eb521faf57c7ed341d0eb6)), closes [#7605](https://github.com/aws/aws-cdk/issues/7605) [#7604](https://github.com/aws/aws-cdk/issues/7604)
18+
* **cli:** `cdk context --reset <number>` does not work ([#10753](https://github.com/aws/aws-cdk/issues/10753)) ([2f3a167](https://github.com/aws/aws-cdk/commit/2f3a167797e60fd2df6c83bc2f3906ddc8eb8966)), closes [#3033](https://github.com/aws/aws-cdk/issues/3033) [#10619](https://github.com/aws/aws-cdk/issues/10619)
19+
* **cli:** failure if account cache is malformed ([#10887](https://github.com/aws/aws-cdk/issues/10887)) ([9b2438a](https://github.com/aws/aws-cdk/commit/9b2438a6e78fc7a9622e79b1435ea6f8b76d98f7))
20+
* **lambda-python:** asset hashes changed ([#10959](https://github.com/aws/aws-cdk/issues/10959)) ([b8de264](https://github.com/aws/aws-cdk/commit/b8de264af75aed11e14fb715f40d6d2e41d5233e)), closes [#10958](https://github.com/aws/aws-cdk/issues/10958) [#10957](https://github.com/aws/aws-cdk/issues/10957)
21+
522
## [1.68.0](https://github.com/aws/aws-cdk/compare/v1.67.0...v1.68.0) (2020-10-15)
623

724

build.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ done
3737
export PATH=$(npm bin):$PATH
3838
export NODE_OPTIONS="--max-old-space-size=4096 ${NODE_OPTIONS:-}"
3939

40+
if ! [ -x "$(command -v yarn)" ]; then
41+
echo "yarn is not installed. Install it from here- https://yarnpkg.com/en/docs/install."
42+
exit 1
43+
fi
44+
4045
echo "============================================================================================="
4146
echo "installing..."
4247
yarn install --frozen-lockfile --network-timeout 1000000
@@ -65,11 +70,6 @@ rm -rf $BUILD_INDICATOR
6570
export MERKLE_BUILD_CACHE=$(mktemp -d)
6671
trap "rm -rf $MERKLE_BUILD_CACHE" EXIT
6772

68-
if ! [ -x "$(command -v yarn)" ]; then
69-
echo "yarn is not installed. Install it from here- https://yarnpkg.com/en/docs/install."
70-
exit 1
71-
fi
72-
7373
echo "============================================================================================="
7474
echo "building..."
7575
time lerna run $bail --stream $runtarget || fail

lerna.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@
1111
"tools/*"
1212
],
1313
"rejectCycles": "true",
14-
"version": "1.68.0"
14+
"version": "1.69.0"
1515
}

packages/@aws-cdk/alexa-ask/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "Alexa::ASK",

packages/@aws-cdk/aws-accessanalyzer/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"compat": "cdk-compat",
5252
"build+test": "npm run build && npm test",
53-
"build+test+package": "npm run build+test && npm run package"
53+
"build+test+package": "npm run build+test && npm run package",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::AccessAnalyzer",

packages/@aws-cdk/aws-acmpca/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::ACMPCA",

packages/@aws-cdk/aws-amazonmq/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::AmazonMQ",

packages/@aws-cdk/aws-amplify/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test": "npm run build && npm test",
5252
"build+test+package": "npm run build+test && npm run package",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::Amplify",

packages/@aws-cdk/aws-apigateway/lib/base-path-mapping.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { Resource, Token } from '@aws-cdk/core';
22
import { Construct } from 'constructs';
33
import { CfnBasePathMapping } from './apigateway.generated';
44
import { IDomainName } from './domain-name';
5-
import { IRestApi, RestApi } from './restapi';
5+
import { IRestApi, RestApiBase } from './restapi';
66
import { Stage } from './stage';
77

88
export interface BasePathMappingOptions {
@@ -55,7 +55,7 @@ export class BasePathMapping extends Resource {
5555

5656
// if restApi is an owned API and it has a deployment stage, map all requests
5757
// to that stage. otherwise, the stage will have to be specified in the URL.
58-
const stage = props.stage ?? (props.restApi instanceof RestApi
58+
const stage = props.stage ?? (props.restApi instanceof RestApiBase
5959
? props.restApi.deploymentStage
6060
: undefined);
6161

packages/@aws-cdk/aws-apigateway/lib/integrations/lambda.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export class LambdaIntegration extends AwsIntegration {
4949
});
5050

5151
this.handler = handler;
52-
this.enableTest = options.allowTestInvoke === undefined ? true : false;
52+
this.enableTest = options.allowTestInvoke === undefined ? true : options.allowTestInvoke;
5353
}
5454

5555
public bind(method: Method): IntegrationConfig {

packages/@aws-cdk/aws-apigateway/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@
4949
"cfn2ts": "cfn2ts",
5050
"build+test+package": "npm run build+test && npm run package",
5151
"build+test": "npm run build && npm test",
52-
"compat": "cdk-compat"
52+
"compat": "cdk-compat",
53+
"gen": "cfn2ts"
5354
},
5455
"cdk-build": {
5556
"cloudformation": "AWS::ApiGateway",

packages/@aws-cdk/aws-apigateway/test/test.domains.ts

+59
Original file line numberDiff line numberDiff line change
@@ -443,4 +443,63 @@ export = {
443443
test.done();
444444
},
445445

446+
'base path mapping configures stage for RestApi creation'(test: Test) {
447+
// GIVEN
448+
const stack = new Stack();
449+
new apigw.RestApi(stack, 'restApiWithStage', {
450+
domainName: {
451+
domainName: 'example.com',
452+
certificate: acm.Certificate.fromCertificateArn(stack, 'cert', 'arn:aws:acm:us-east-1:1111111:certificate/11-3336f1-44483d-adc7-9cd375c5169d'),
453+
endpointType: apigw.EndpointType.REGIONAL,
454+
},
455+
}).root.addMethod('GET');
456+
457+
// THEN
458+
expect(stack).to(haveResource('AWS::ApiGateway::BasePathMapping', {
459+
'DomainName': {
460+
'Ref': 'restApiWithStageCustomDomainC4749625',
461+
},
462+
'RestApiId': {
463+
'Ref': 'restApiWithStageD4F931D0',
464+
},
465+
'Stage': {
466+
'Ref': 'restApiWithStageDeploymentStageprodC82A6648',
467+
},
468+
}));
469+
470+
test.done();
471+
},
472+
473+
'base path mapping configures stage for SpecRestApi creation'(test: Test) {
474+
// GIVEN
475+
const stack = new Stack();
476+
477+
const definition = {
478+
key1: 'val1',
479+
};
480+
481+
new apigw.SpecRestApi(stack, 'specRestApiWithStage', {
482+
apiDefinition: apigw.ApiDefinition.fromInline(definition),
483+
domainName: {
484+
domainName: 'example.com',
485+
certificate: acm.Certificate.fromCertificateArn(stack, 'cert', 'arn:aws:acm:us-east-1:1111111:certificate/11-3336f1-44483d-adc7-9cd375c5169d'),
486+
endpointType: apigw.EndpointType.REGIONAL,
487+
},
488+
}).root.addMethod('GET');
489+
490+
// THEN
491+
expect(stack).to(haveResource('AWS::ApiGateway::BasePathMapping', {
492+
'DomainName': {
493+
'Ref': 'specRestApiWithStageCustomDomain8A36A5C9',
494+
},
495+
'RestApiId': {
496+
'Ref': 'specRestApiWithStageC1492575',
497+
},
498+
'Stage': {
499+
'Ref': 'specRestApiWithStageDeploymentStageprod2D3037ED',
500+
},
501+
}));
502+
503+
test.done();
504+
},
446505
};

packages/@aws-cdk/aws-apigateway/test/test.lambda.ts

+38
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,44 @@ export = {
102102
test.done();
103103
},
104104

105+
'"allowTestInvoke" set to true allows calling the API from the test UI'(test: Test) {
106+
// GIVEN
107+
const stack = new cdk.Stack();
108+
const fn = new lambda.Function(stack, 'Handler', {
109+
runtime: lambda.Runtime.NODEJS_10_X,
110+
code: lambda.Code.fromInline('foo'),
111+
handler: 'index.handler',
112+
});
113+
114+
const api = new apigateway.RestApi(stack, 'api');
115+
116+
// WHEN
117+
const integ = new apigateway.LambdaIntegration(fn, { allowTestInvoke: true });
118+
api.root.addMethod('GET', integ);
119+
120+
// THEN
121+
expect(stack).to(haveResource('AWS::Lambda::Permission', {
122+
SourceArn: {
123+
'Fn::Join': [
124+
'',
125+
[
126+
'arn:',
127+
{ Ref: 'AWS::Partition' },
128+
':execute-api:',
129+
{ Ref: 'AWS::Region' },
130+
':',
131+
{ Ref: 'AWS::AccountId' },
132+
':',
133+
{ Ref: 'apiC8550315' },
134+
'/test-invoke-stage/GET/',
135+
],
136+
],
137+
},
138+
}));
139+
140+
test.done();
141+
},
142+
105143
'"proxy" can be used to disable proxy mode'(test: Test) {
106144
// GIVEN
107145
const stack = new cdk.Stack();

packages/@aws-cdk/aws-apigatewayv2/lib/http/api.ts

+7
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,12 @@ export interface HttpApiProps {
8585
*/
8686
readonly apiName?: string;
8787

88+
/**
89+
* The description of the API.
90+
* @default - none
91+
*/
92+
readonly description?: string;
93+
8894
/**
8995
* An integration that will be configured on the catch-all route ($default).
9096
* @default - none
@@ -267,6 +273,7 @@ export class HttpApi extends HttpApiBase {
267273
name: this.httpApiName,
268274
protocolType: 'HTTP',
269275
corsConfiguration,
276+
description: props?.description,
270277
};
271278

272279
const resource = new CfnApi(this, 'Resource', apiProps);

packages/@aws-cdk/aws-apigatewayv2/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"compat": "cdk-compat",
5252
"build+test": "npm run build && npm test",
53-
"build+test+package": "npm run build+test && npm run package"
53+
"build+test+package": "npm run build+test && npm run package",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::ApiGatewayV2",

packages/@aws-cdk/aws-apigatewayv2/test/http/api.test.ts

+13
Original file line numberDiff line numberDiff line change
@@ -220,4 +220,17 @@ describe('HttpApi', () => {
220220
expect(countMetric.statistic).toEqual(statistic);
221221
});
222222
});
223+
224+
test('description is set', () => {
225+
const stack = new Stack();
226+
new HttpApi(stack, 'api', {
227+
description: 'My Api',
228+
});
229+
230+
expect(stack).toHaveResource('AWS::ApiGatewayV2::Api', {
231+
Name: 'api',
232+
ProtocolType: 'HTTP',
233+
Description: 'My Api',
234+
});
235+
});
223236
});

packages/@aws-cdk/aws-appconfig/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::AppConfig",

packages/@aws-cdk/aws-appflow/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::AppFlow",

packages/@aws-cdk/aws-applicationautoscaling/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@
4949
"cfn2ts": "cfn2ts",
5050
"build+test+package": "npm run build+test && npm run package",
5151
"build+test": "npm run build && npm test",
52-
"compat": "cdk-compat"
52+
"compat": "cdk-compat",
53+
"gen": "cfn2ts"
5354
},
5455
"cdk-build": {
5556
"cloudformation": "AWS::ApplicationAutoScaling",

packages/@aws-cdk/aws-applicationinsights/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::ApplicationInsights",

packages/@aws-cdk/aws-appmesh/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
"cfn2ts": "cfn2ts",
5151
"build+test+package": "npm run build+test && npm run package",
5252
"build+test": "npm run build && npm test",
53-
"compat": "cdk-compat"
53+
"compat": "cdk-compat",
54+
"gen": "cfn2ts"
5455
},
5556
"cdk-build": {
5657
"cloudformation": "AWS::AppMesh",

0 commit comments

Comments
 (0)