Skip to content

Commit d50c022

Browse files
author
awstools
committed
feat(client-amplify): Introduced support for Skew Protection. Added enableSkewProtection field to createBranch and updateBranch API.
1 parent 89baba5 commit d50c022

File tree

8 files changed

+76
-12
lines changed

8 files changed

+76
-12
lines changed

clients/client-amplify/src/commands/CreateBranchCommand.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ export interface CreateBranchCommandOutput extends CreateBranchResult, __Metadat
4848
* framework: "STRING_VALUE",
4949
* enableNotification: true || false,
5050
* enableAutoBuild: true || false,
51+
* enableSkewProtection: true || false,
5152
* environmentVariables: { // EnvironmentVariables
5253
* "<keys>": "STRING_VALUE",
5354
* },
@@ -87,6 +88,7 @@ export interface CreateBranchCommandOutput extends CreateBranchResult, __Metadat
8788
* // "<keys>": "STRING_VALUE",
8889
* // },
8990
* // enableAutoBuild: true || false, // required
91+
* // enableSkewProtection: true || false,
9092
* // customDomains: [ // CustomDomains // required
9193
* // "STRING_VALUE",
9294
* // ],

clients/client-amplify/src/commands/DeleteBranchCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ export interface DeleteBranchCommandOutput extends DeleteBranchResult, __Metadat
5858
* // "<keys>": "STRING_VALUE",
5959
* // },
6060
* // enableAutoBuild: true || false, // required
61+
* // enableSkewProtection: true || false,
6162
* // customDomains: [ // CustomDomains // required
6263
* // "STRING_VALUE",
6364
* // ],

clients/client-amplify/src/commands/GetBranchCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ export interface GetBranchCommandOutput extends GetBranchResult, __MetadataBeare
5858
* // "<keys>": "STRING_VALUE",
5959
* // },
6060
* // enableAutoBuild: true || false, // required
61+
* // enableSkewProtection: true || false,
6162
* // customDomains: [ // CustomDomains // required
6263
* // "STRING_VALUE",
6364
* // ],

clients/client-amplify/src/commands/ListBranchesCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export interface ListBranchesCommandOutput extends ListBranchesResult, __Metadat
6060
* // "<keys>": "STRING_VALUE",
6161
* // },
6262
* // enableAutoBuild: true || false, // required
63+
* // enableSkewProtection: true || false,
6364
* // customDomains: [ // CustomDomains // required
6465
* // "STRING_VALUE",
6566
* // ],

clients/client-amplify/src/commands/UpdateBranchCommand.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ export interface UpdateBranchCommandOutput extends UpdateBranchResult, __Metadat
4848
* stage: "PRODUCTION" || "BETA" || "DEVELOPMENT" || "EXPERIMENTAL" || "PULL_REQUEST",
4949
* enableNotification: true || false,
5050
* enableAutoBuild: true || false,
51+
* enableSkewProtection: true || false,
5152
* environmentVariables: { // EnvironmentVariables
5253
* "<keys>": "STRING_VALUE",
5354
* },
@@ -84,6 +85,7 @@ export interface UpdateBranchCommandOutput extends UpdateBranchResult, __Metadat
8485
* // "<keys>": "STRING_VALUE",
8586
* // },
8687
* // enableAutoBuild: true || false, // required
88+
* // enableSkewProtection: true || false,
8789
* // customDomains: [ // CustomDomains // required
8890
* // "STRING_VALUE",
8991
* // ],

clients/client-amplify/src/models/models_0.ts

Lines changed: 39 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ export interface CreateAppRequest {
253253
/**
254254
* <p>The Amazon Resource Name (ARN) of the IAM role to assign to an SSR app. The SSR Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
255255
* based on the role's permissions. For more information about the SSR Compute role, see
256-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
256+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
257257
* Guide</i>.</p>
258258
* @public
259259
*/
@@ -544,7 +544,7 @@ export interface App {
544544
/**
545545
* <p>The Amazon Resource Name (ARN) of the IAM role for an SSR app. The Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
546546
* based on the role's permissions. For more information about the SSR Compute role, see
547-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
547+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
548548
* Guide</i>.</p>
549549
* @public
550550
*/
@@ -942,6 +942,17 @@ export interface CreateBranchRequest {
942942
*/
943943
enableAutoBuild?: boolean | undefined;
944944

945+
/**
946+
* <p>Specifies whether the skew protection feature is enabled for the branch.</p>
947+
* <p>Deployment skew protection is available to Amplify applications to eliminate version skew
948+
* issues between client and servers in web applications. When you apply skew protection to a branch, you can ensure that your clients always interact with the correct version
949+
* of server-side assets, regardless of when a deployment occurs. For more information about skew protection, see
950+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/skew-protection.html">Skew protection for Amplify deployments</a> in the <i>Amplify User
951+
* Guide</i>.</p>
952+
* @public
953+
*/
954+
enableSkewProtection?: boolean | undefined;
955+
945956
/**
946957
* <p> The environment variables for the branch. </p>
947958
* @public
@@ -1030,7 +1041,7 @@ export interface CreateBranchRequest {
10301041
/**
10311042
* <p>The Amazon Resource Name (ARN) of the IAM role to assign to a branch of an SSR app. The SSR Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
10321043
* based on the role's permissions. For more information about the SSR Compute role, see
1033-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
1044+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
10341045
* Guide</i>.</p>
10351046
* @public
10361047
*/
@@ -1108,6 +1119,17 @@ export interface Branch {
11081119
*/
11091120
enableAutoBuild: boolean | undefined;
11101121

1122+
/**
1123+
* <p>Specifies whether the skew protection feature is enabled for the branch.</p>
1124+
* <p>Deployment skew protection is available to Amplify applications to eliminate version skew
1125+
* issues between client and servers in web applications. When you apply skew protection to a branch, you can ensure that your clients always interact with the correct version
1126+
* of server-side assets, regardless of when a deployment occurs. For more information about skew protection, see
1127+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/skew-protection.html">Skew protection for Amplify deployments</a> in the <i>Amplify User
1128+
* Guide</i>.</p>
1129+
* @public
1130+
*/
1131+
enableSkewProtection?: boolean | undefined;
1132+
11111133
/**
11121134
* <p> The custom domains for a branch of an Amplify app. </p>
11131135
* @public
@@ -1226,7 +1248,7 @@ export interface Branch {
12261248
/**
12271249
* <p>The Amazon Resource Name (ARN) of the IAM role for a branch of an SSR app. The Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
12281250
* based on the role's permissions. For more information about the SSR Compute role, see
1229-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
1251+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
12301252
* Guide</i>.</p>
12311253
* @public
12321254
*/
@@ -3018,7 +3040,7 @@ export interface UpdateAppRequest {
30183040
/**
30193041
* <p>The Amazon Resource Name (ARN) of the IAM role to assign to an SSR app. The SSR Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
30203042
* based on the role's permissions. For more information about the SSR Compute role, see
3021-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
3043+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
30223044
* Guide</i>.</p>
30233045
* @public
30243046
*/
@@ -3206,6 +3228,17 @@ export interface UpdateBranchRequest {
32063228
*/
32073229
enableAutoBuild?: boolean | undefined;
32083230

3231+
/**
3232+
* <p>Specifies whether the skew protection feature is enabled for the branch.</p>
3233+
* <p>Deployment skew protection is available to Amplify applications to eliminate version skew
3234+
* issues between client and servers in web applications. When you apply skew protection to a branch, you can ensure that your clients always interact with the correct version
3235+
* of server-side assets, regardless of when a deployment occurs. For more information about skew protection, see
3236+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/skew-protection.html">Skew protection for Amplify deployments</a> in the <i>Amplify User
3237+
* Guide</i>.</p>
3238+
* @public
3239+
*/
3240+
enableSkewProtection?: boolean | undefined;
3241+
32093242
/**
32103243
* <p> The environment variables for the branch. </p>
32113244
* @public
@@ -3288,7 +3321,7 @@ export interface UpdateBranchRequest {
32883321
/**
32893322
* <p>The Amazon Resource Name (ARN) of the IAM role to assign to a branch of an SSR app. The SSR Compute role allows the Amplify Hosting compute service to securely access specific Amazon Web Services resources
32903323
* based on the role's permissions. For more information about the SSR Compute role, see
3291-
* <a href="https://docs.aws.amazon.com/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
3324+
* <a href="https://docs.aws.amazon.com/amplify/latest/userguide/amplify-SSR-compute-role.html">Adding an SSR Compute role</a> in the <i>Amplify User
32923325
* Guide</i>.</p>
32933326
* @public
32943327
*/

clients/client-amplify/src/protocols/Aws_restJson1.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@ export const se_CreateBranchCommand = async (
212212
enableNotification: [],
213213
enablePerformanceMode: [],
214214
enablePullRequestPreview: [],
215+
enableSkewProtection: [],
215216
environmentVariables: (_) => _json(_),
216217
framework: [],
217218
pullRequestEnvironmentName: [],
@@ -882,6 +883,7 @@ export const se_UpdateBranchCommand = async (
882883
enableNotification: [],
883884
enablePerformanceMode: [],
884885
enablePullRequestPreview: [],
886+
enableSkewProtection: [],
885887
environmentVariables: (_) => _json(_),
886888
framework: [],
887889
pullRequestEnvironmentName: [],
@@ -2039,6 +2041,7 @@ const de_Branch = (output: any, context: __SerdeContext): Branch => {
20392041
enableNotification: __expectBoolean,
20402042
enablePerformanceMode: __expectBoolean,
20412043
enablePullRequestPreview: __expectBoolean,
2044+
enableSkewProtection: __expectBoolean,
20422045
environmentVariables: _json,
20432046
framework: __expectString,
20442047
pullRequestEnvironmentName: __expectString,

0 commit comments

Comments
 (0)