Skip to content

Commit 59f9e1a

Browse files
author
awstools
committed
feat(client-cloudhsm-v2): Added support for hsm type hsm2m.medium. Added supported for creating a cluster in FIPS or NON_FIPS mode.
1 parent b0de95c commit 59f9e1a

11 files changed

+111
-5
lines changed

clients/client-cloudhsm-v2/src/commands/CreateClusterCommand.ts

+2
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ export interface CreateClusterCommandOutput extends CreateClusterResponse, __Met
5151
* Value: "STRING_VALUE", // required
5252
* },
5353
* ],
54+
* Mode: "FIPS" || "NON_FIPS",
5455
* };
5556
* const command = new CreateClusterCommand(input);
5657
* const response = await client.send(command);
@@ -98,6 +99,7 @@ export interface CreateClusterCommandOutput extends CreateClusterResponse, __Met
9899
* // Value: "STRING_VALUE", // required
99100
* // },
100101
* // ],
102+
* // Mode: "FIPS" || "NON_FIPS",
101103
* // },
102104
* // };
103105
*

clients/client-cloudhsm-v2/src/commands/DeleteBackupCommand.ts

+2
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ export interface DeleteBackupCommandOutput extends DeleteBackupResponse, __Metad
6060
* // Value: "STRING_VALUE", // required
6161
* // },
6262
* // ],
63+
* // HsmType: "STRING_VALUE",
64+
* // Mode: "FIPS" || "NON_FIPS",
6365
* // },
6466
* // };
6567
*

clients/client-cloudhsm-v2/src/commands/DeleteClusterCommand.ts

+1
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ export interface DeleteClusterCommandOutput extends DeleteClusterResponse, __Met
8585
* // Value: "STRING_VALUE", // required
8686
* // },
8787
* // ],
88+
* // Mode: "FIPS" || "NON_FIPS",
8889
* // },
8990
* // };
9091
*

clients/client-cloudhsm-v2/src/commands/DescribeBackupsCommand.ts

+2
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ export interface DescribeBackupsCommandOutput extends DescribeBackupsResponse, _
7171
* // Value: "STRING_VALUE", // required
7272
* // },
7373
* // ],
74+
* // HsmType: "STRING_VALUE",
75+
* // Mode: "FIPS" || "NON_FIPS",
7476
* // },
7577
* // ],
7678
* // NextToken: "STRING_VALUE",

clients/client-cloudhsm-v2/src/commands/DescribeClustersCommand.ts

+1
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ export interface DescribeClustersCommandOutput extends DescribeClustersResponse,
9696
* // Value: "STRING_VALUE", // required
9797
* // },
9898
* // ],
99+
* // Mode: "FIPS" || "NON_FIPS",
99100
* // },
100101
* // ],
101102
* // NextToken: "STRING_VALUE",

clients/client-cloudhsm-v2/src/commands/ModifyBackupAttributesCommand.ts

+2
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ export interface ModifyBackupAttributesCommandOutput extends ModifyBackupAttribu
5959
* // Value: "STRING_VALUE", // required
6060
* // },
6161
* // ],
62+
* // HsmType: "STRING_VALUE",
63+
* // Mode: "FIPS" || "NON_FIPS",
6264
* // },
6365
* // };
6466
*

clients/client-cloudhsm-v2/src/commands/ModifyClusterCommand.ts

+1
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ export interface ModifyClusterCommandOutput extends ModifyClusterResponse, __Met
8888
* // Value: "STRING_VALUE", // required
8989
* // },
9090
* // ],
91+
* // Mode: "FIPS" || "NON_FIPS",
9192
* // },
9293
* // };
9394
*

clients/client-cloudhsm-v2/src/commands/RestoreBackupCommand.ts

+2
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ export interface RestoreBackupCommandOutput extends RestoreBackupResponse, __Met
6060
* // Value: "STRING_VALUE", // required
6161
* // },
6262
* // ],
63+
* // HsmType: "STRING_VALUE",
64+
* // Mode: "FIPS" || "NON_FIPS",
6365
* // },
6466
* // };
6567
*

clients/client-cloudhsm-v2/src/models/models_0.ts

+41-2
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,20 @@ export const BackupState = {
1919
*/
2020
export type BackupState = (typeof BackupState)[keyof typeof BackupState];
2121

22+
/**
23+
* @public
24+
* @enum
25+
*/
26+
export const ClusterMode = {
27+
FIPS: "FIPS",
28+
NON_FIPS: "NON_FIPS",
29+
} as const;
30+
31+
/**
32+
* @public
33+
*/
34+
export type ClusterMode = (typeof ClusterMode)[keyof typeof ClusterMode];
35+
2236
/**
2337
* <p>Contains a tag. A tag is a key-value pair.</p>
2438
* @public
@@ -116,6 +130,18 @@ export interface Backup {
116130
* @public
117131
*/
118132
TagList?: Tag[];
133+
134+
/**
135+
* <p>The HSM type of the cluster that was backed up.</p>
136+
* @public
137+
*/
138+
HsmType?: string;
139+
140+
/**
141+
* <p>The mode of the cluster that was backed up.</p>
142+
* @public
143+
*/
144+
Mode?: ClusterMode;
119145
}
120146

121147
/**
@@ -378,8 +404,8 @@ export interface CreateClusterRequest {
378404
BackupRetentionPolicy?: BackupRetentionPolicy;
379405

380406
/**
381-
* <p>The type of HSM to use in the cluster. Currently the only allowed value is
382-
* <code>hsm1.medium</code>.</p>
407+
* <p>The type of HSM to use in the cluster. The allowed values are
408+
* <code>hsm1.medium</code> and <code>hsm2m.medium</code>.</p>
383409
* @public
384410
*/
385411
HsmType: string | undefined;
@@ -412,6 +438,13 @@ export interface CreateClusterRequest {
412438
* @public
413439
*/
414440
TagList?: Tag[];
441+
442+
/**
443+
* <p>The mode to use in the cluster. The allowed values are
444+
* <code>FIPS</code> and <code>NON_FIPS</code>.</p>
445+
* @public
446+
*/
447+
Mode?: ClusterMode;
415448
}
416449

417450
/**
@@ -641,6 +674,12 @@ export interface Cluster {
641674
* @public
642675
*/
643676
TagList?: Tag[];
677+
678+
/**
679+
* <p>The mode of the cluster.</p>
680+
* @public
681+
*/
682+
Mode?: ClusterMode;
644683
}
645684

646685
/**

clients/client-cloudhsm-v2/src/protocols/Aws_json1_1.ts

+3
Original file line numberDiff line numberDiff line change
@@ -761,6 +761,8 @@ const de_Backup = (output: any, context: __SerdeContext): Backup => {
761761
CopyTimestamp: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
762762
CreateTimestamp: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
763763
DeleteTimestamp: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
764+
HsmType: __expectString,
765+
Mode: __expectString,
764766
NeverExpires: __expectBoolean,
765767
SourceBackup: __expectString,
766768
SourceCluster: __expectString,
@@ -809,6 +811,7 @@ const de_Cluster = (output: any, context: __SerdeContext): Cluster => {
809811
CreateTimestamp: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
810812
HsmType: __expectString,
811813
Hsms: _json,
814+
Mode: __expectString,
812815
PreCoPassword: __expectString,
813816
SecurityGroup: __expectString,
814817
SourceBackupId: __expectString,

codegen/sdk-codegen/aws-models/cloudhsm-v2.json

+54-3
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,18 @@
9898
"traits": {
9999
"smithy.api#documentation": "<p>The list of tags for the backup.</p>"
100100
}
101+
},
102+
"HsmType": {
103+
"target": "com.amazonaws.cloudhsmv2#HsmType",
104+
"traits": {
105+
"smithy.api#documentation": "<p>The HSM type of the cluster that was backed up.</p>"
106+
}
107+
},
108+
"Mode": {
109+
"target": "com.amazonaws.cloudhsmv2#ClusterMode",
110+
"traits": {
111+
"smithy.api#documentation": "<p>The mode of the cluster that was backed up.</p>"
112+
}
101113
}
102114
},
103115
"traits": {
@@ -1232,7 +1244,7 @@
12321244
"traits": {
12331245
"smithy.api#length": {
12341246
"min": 0,
1235-
"max": 5000
1247+
"max": 20000
12361248
},
12371249
"smithy.api#pattern": "^[a-zA-Z0-9+-/=\\s]*$"
12381250
}
@@ -1439,6 +1451,12 @@
14391451
"traits": {
14401452
"smithy.api#documentation": "<p>The list of tags for the cluster.</p>"
14411453
}
1454+
},
1455+
"Mode": {
1456+
"target": "com.amazonaws.cloudhsmv2#ClusterMode",
1457+
"traits": {
1458+
"smithy.api#documentation": "<p>The mode of the cluster.</p>"
1459+
}
14421460
}
14431461
},
14441462
"traits": {
@@ -1451,6 +1469,23 @@
14511469
"smithy.api#pattern": "^cluster-[2-7a-zA-Z]{11,16}$"
14521470
}
14531471
},
1472+
"com.amazonaws.cloudhsmv2#ClusterMode": {
1473+
"type": "enum",
1474+
"members": {
1475+
"FIPS": {
1476+
"target": "smithy.api#Unit",
1477+
"traits": {
1478+
"smithy.api#enumValue": "FIPS"
1479+
}
1480+
},
1481+
"NON_FIPS": {
1482+
"target": "smithy.api#Unit",
1483+
"traits": {
1484+
"smithy.api#enumValue": "NON_FIPS"
1485+
}
1486+
}
1487+
}
1488+
},
14541489
"com.amazonaws.cloudhsmv2#ClusterState": {
14551490
"type": "enum",
14561491
"members": {
@@ -1643,7 +1678,7 @@
16431678
"HsmType": {
16441679
"target": "com.amazonaws.cloudhsmv2#HsmType",
16451680
"traits": {
1646-
"smithy.api#documentation": "<p>The type of HSM to use in the cluster. Currently the only allowed value is\n <code>hsm1.medium</code>.</p>",
1681+
"smithy.api#documentation": "<p>The type of HSM to use in the cluster. The allowed values are\n <code>hsm1.medium</code> and <code>hsm2m.medium</code>.</p>",
16471682
"smithy.api#required": {}
16481683
}
16491684
},
@@ -1665,6 +1700,12 @@
16651700
"traits": {
16661701
"smithy.api#documentation": "<p>Tags to apply to the CloudHSM cluster during creation.</p>"
16671702
}
1703+
},
1704+
"Mode": {
1705+
"target": "com.amazonaws.cloudhsmv2#ClusterMode",
1706+
"traits": {
1707+
"smithy.api#documentation": "<p>The mode to use in the cluster. The allowed values are\n <code>FIPS</code> and <code>NON_FIPS</code>.</p>"
1708+
}
16681709
}
16691710
},
16701711
"traits": {
@@ -2186,6 +2227,12 @@
21862227
},
21872228
"value": {
21882229
"target": "com.amazonaws.cloudhsmv2#Strings"
2230+
},
2231+
"traits": {
2232+
"smithy.api#length": {
2233+
"min": 0,
2234+
"max": 30
2235+
}
21892236
}
21902237
},
21912238
"com.amazonaws.cloudhsmv2#Hsm": {
@@ -2289,7 +2336,11 @@
22892336
"com.amazonaws.cloudhsmv2#HsmType": {
22902337
"type": "string",
22912338
"traits": {
2292-
"smithy.api#pattern": "^(hsm1\\.medium)$"
2339+
"smithy.api#length": {
2340+
"min": 0,
2341+
"max": 32
2342+
},
2343+
"smithy.api#pattern": "^((p|)hsm[0-9][a-z.]*\\.[a-zA-Z]+)$"
22932344
}
22942345
},
22952346
"com.amazonaws.cloudhsmv2#Hsms": {

0 commit comments

Comments
 (0)