Skip to content

Commit

Permalink
feat(client-cloudhsm-v2): Adds support to ModifyCluster for modifying…
Browse files Browse the repository at this point in the history
… a Cluster's Hsm Type.
  • Loading branch information
awstools committed Jan 7, 2025
1 parent 5e4350e commit b2cbba5
Show file tree
Hide file tree
Showing 8 changed files with 55 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,13 @@ export interface CreateClusterCommandOutput extends CreateClusterResponse, __Met
* // EniIp: "STRING_VALUE",
* // EniIpV6: "STRING_VALUE",
* // HsmId: "STRING_VALUE", // required
* // HsmType: "STRING_VALUE",
* // State: "CREATE_IN_PROGRESS" || "ACTIVE" || "DEGRADED" || "DELETE_IN_PROGRESS" || "DELETED",
* // StateMessage: "STRING_VALUE",
* // },
* // ],
* // HsmType: "STRING_VALUE",
* // HsmTypeRollbackExpiration: new Date("TIMESTAMP"),
* // PreCoPassword: "STRING_VALUE",
* // SecurityGroup: "STRING_VALUE",
* // SourceBackupId: "STRING_VALUE",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export interface CreateHsmCommandOutput extends CreateHsmResponse, __MetadataBea
* // EniIp: "STRING_VALUE",
* // EniIpV6: "STRING_VALUE",
* // HsmId: "STRING_VALUE", // required
* // HsmType: "STRING_VALUE",
* // State: "CREATE_IN_PROGRESS" || "ACTIVE" || "DEGRADED" || "DELETE_IN_PROGRESS" || "DELETED",
* // StateMessage: "STRING_VALUE",
* // },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,13 @@ export interface DeleteClusterCommandOutput extends DeleteClusterResponse, __Met
* // EniIp: "STRING_VALUE",
* // EniIpV6: "STRING_VALUE",
* // HsmId: "STRING_VALUE", // required
* // HsmType: "STRING_VALUE",
* // State: "CREATE_IN_PROGRESS" || "ACTIVE" || "DEGRADED" || "DELETE_IN_PROGRESS" || "DELETED",
* // StateMessage: "STRING_VALUE",
* // },
* // ],
* // HsmType: "STRING_VALUE",
* // HsmTypeRollbackExpiration: new Date("TIMESTAMP"),
* // PreCoPassword: "STRING_VALUE",
* // SecurityGroup: "STRING_VALUE",
* // SourceBackupId: "STRING_VALUE",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,13 @@ export interface DescribeClustersCommandOutput extends DescribeClustersResponse,
* // EniIp: "STRING_VALUE",
* // EniIpV6: "STRING_VALUE",
* // HsmId: "STRING_VALUE", // required
* // HsmType: "STRING_VALUE",
* // State: "CREATE_IN_PROGRESS" || "ACTIVE" || "DEGRADED" || "DELETE_IN_PROGRESS" || "DELETED",
* // StateMessage: "STRING_VALUE",
* // },
* // ],
* // HsmType: "STRING_VALUE",
* // HsmTypeRollbackExpiration: new Date("TIMESTAMP"),
* // PreCoPassword: "STRING_VALUE",
* // SecurityGroup: "STRING_VALUE",
* // SourceBackupId: "STRING_VALUE",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ export interface ModifyClusterCommandOutput extends ModifyClusterResponse, __Met
* // const { CloudHSMV2Client, ModifyClusterCommand } = require("@aws-sdk/client-cloudhsm-v2"); // CommonJS import
* const client = new CloudHSMV2Client(config);
* const input = { // ModifyClusterRequest
* HsmType: "STRING_VALUE",
* BackupRetentionPolicy: { // BackupRetentionPolicy
* Type: "DAYS",
* Value: "STRING_VALUE",
Expand All @@ -64,11 +65,13 @@ export interface ModifyClusterCommandOutput extends ModifyClusterResponse, __Met
* // EniIp: "STRING_VALUE",
* // EniIpV6: "STRING_VALUE",
* // HsmId: "STRING_VALUE", // required
* // HsmType: "STRING_VALUE",
* // State: "CREATE_IN_PROGRESS" || "ACTIVE" || "DEGRADED" || "DELETE_IN_PROGRESS" || "DELETED",
* // StateMessage: "STRING_VALUE",
* // },
* // ],
* // HsmType: "STRING_VALUE",
* // HsmTypeRollbackExpiration: new Date("TIMESTAMP"),
* // PreCoPassword: "STRING_VALUE",
* // SecurityGroup: "STRING_VALUE",
* // SourceBackupId: "STRING_VALUE",
Expand Down
30 changes: 24 additions & 6 deletions clients/client-cloudhsm-v2/src/models/models_0.ts
Original file line number Diff line number Diff line change
Expand Up @@ -579,6 +579,12 @@ export interface Hsm {
*/
HsmId: string | undefined;

/**
* <p>The type of HSM.</p>
* @public
*/
HsmType?: string | undefined;

/**
* <p>The HSM's state.</p>
* @public
Expand Down Expand Up @@ -656,6 +662,12 @@ export interface Cluster {
*/
HsmType?: string | undefined;

/**
* <p>The timestamp until when the cluster can be rolled back to its original HSM type.</p>
* @public
*/
HsmTypeRollbackExpiration?: Date | undefined;

/**
* <p>The default password for the cluster's Pre-Crypto Officer (PRECO) user.</p>
* @public
Expand Down Expand Up @@ -701,11 +713,11 @@ export interface Cluster {
VpcId?: string | undefined;

/**
* <p>The cluster's NetworkType can be set to either IPV4 (which is the default) or DUALSTACK.
* When set to IPV4, communication between your application and the Hardware Security Modules (HSMs) is restricted to the IPv4 protocol only.
* In contrast, the DUALSTACK network type enables communication over both the IPv4 and IPv6 protocols.
* To use the DUALSTACK option, you'll need to configure your Virtual Private Cloud (VPC) and subnets to support both IPv4 and IPv6. This involves adding IPv6 Classless Inter-Domain Routing (CIDR) blocks to the existing IPv4 CIDR blocks in your subnets.
* The choice between IPV4 and DUALSTACK network types determines the flexibility of the network addressing setup for your cluster. The DUALSTACK option provides more flexibility by allowing both IPv4 and IPv6 communication.</p>
* <p>The cluster's NetworkType can be IPv4 (the default) or DUALSTACK.
* The IPv4 NetworkType restricts communication between your application and the hardware security modules (HSMs) to the IPv4 protocol only. The DUALSTACK NetworkType enables communication over both IPv4 and IPv6 protocols.
* To use DUALSTACK, configure your virtual private cloud (VPC) and subnets to support both IPv4 and IPv6.
* This configuration involves adding IPv6 Classless Inter-Domain Routing (CIDR) blocks to the existing IPv4 CIDR blocks in your subnets.
* The NetworkType you choose affects the network addressing options for your cluster. DUALSTACK provides more flexibility by supporting both IPv4 and IPv6 communication.</p>
* @public
*/
NetworkType?: NetworkType | undefined;
Expand Down Expand Up @@ -1168,11 +1180,17 @@ export interface ModifyBackupAttributesResponse {
* @public
*/
export interface ModifyClusterRequest {
/**
* <p>The desired HSM type of the cluster.</p>
* @public
*/
HsmType?: string | undefined;

/**
* <p>A policy that defines how the service retains backups.</p>
* @public
*/
BackupRetentionPolicy: BackupRetentionPolicy | undefined;
BackupRetentionPolicy?: BackupRetentionPolicy | undefined;

/**
* <p>The identifier (ID) of the cluster that you want to modify. To find the cluster ID, use
Expand Down
1 change: 1 addition & 0 deletions clients/client-cloudhsm-v2/src/protocols/Aws_json1_1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -947,6 +947,7 @@ const de_Cluster = (output: any, context: __SerdeContext): Cluster => {
ClusterId: __expectString,
CreateTimestamp: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
HsmType: __expectString,
HsmTypeRollbackExpiration: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
Hsms: _json,
Mode: __expectString,
NetworkType: __expectString,
Expand Down
23 changes: 20 additions & 3 deletions codegen/sdk-codegen/aws-models/cloudhsm-v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -1437,6 +1437,12 @@
"smithy.api#documentation": "<p>The type of HSM that the cluster contains.</p>"
}
},
"HsmTypeRollbackExpiration": {
"target": "com.amazonaws.cloudhsmv2#Timestamp",
"traits": {
"smithy.api#documentation": "<p>The timestamp until when the cluster can be rolled back to its original HSM type.</p>"
}
},
"PreCoPassword": {
"target": "com.amazonaws.cloudhsmv2#PreCoPassword",
"traits": {
Expand Down Expand Up @@ -1482,7 +1488,7 @@
"NetworkType": {
"target": "com.amazonaws.cloudhsmv2#NetworkType",
"traits": {
"smithy.api#documentation": "<p>The cluster's NetworkType can be set to either IPV4 (which is the default) or DUALSTACK.\n When set to IPV4, communication between your application and the Hardware Security Modules (HSMs) is restricted to the IPv4 protocol only.\n In contrast, the DUALSTACK network type enables communication over both the IPv4 and IPv6 protocols.\n To use the DUALSTACK option, you'll need to configure your Virtual Private Cloud (VPC) and subnets to support both IPv4 and IPv6. This involves adding IPv6 Classless Inter-Domain Routing (CIDR) blocks to the existing IPv4 CIDR blocks in your subnets.\n The choice between IPV4 and DUALSTACK network types determines the flexibility of the network addressing setup for your cluster. The DUALSTACK option provides more flexibility by allowing both IPv4 and IPv6 communication.</p>"
"smithy.api#documentation": "<p>The cluster's NetworkType can be IPv4 (the default) or DUALSTACK.\n The IPv4 NetworkType restricts communication between your application and the hardware security modules (HSMs) to the IPv4 protocol only. The DUALSTACK NetworkType enables communication over both IPv4 and IPv6 protocols.\n To use DUALSTACK, configure your virtual private cloud (VPC) and subnets to support both IPv4 and IPv6.\n This configuration involves adding IPv6 Classless Inter-Domain Routing (CIDR) blocks to the existing IPv4 CIDR blocks in your subnets.\n The NetworkType you choose affects the network addressing options for your cluster. DUALSTACK provides more flexibility by supporting both IPv4 and IPv6 communication.</p>"
}
},
"Certificates": {
Expand Down Expand Up @@ -2483,6 +2489,12 @@
"smithy.api#required": {}
}
},
"HsmType": {
"target": "com.amazonaws.cloudhsmv2#HsmType",
"traits": {
"smithy.api#documentation": "<p>The type of HSM.</p>"
}
},
"State": {
"target": "com.amazonaws.cloudhsmv2#HsmState",
"traits": {
Expand Down Expand Up @@ -2838,11 +2850,16 @@
"com.amazonaws.cloudhsmv2#ModifyClusterRequest": {
"type": "structure",
"members": {
"HsmType": {
"target": "com.amazonaws.cloudhsmv2#HsmType",
"traits": {
"smithy.api#documentation": "<p>The desired HSM type of the cluster.</p>"
}
},
"BackupRetentionPolicy": {
"target": "com.amazonaws.cloudhsmv2#BackupRetentionPolicy",
"traits": {
"smithy.api#documentation": "<p>A policy that defines how the service retains backups.</p>",
"smithy.api#required": {}
"smithy.api#documentation": "<p>A policy that defines how the service retains backups.</p>"
}
},
"ClusterId": {
Expand Down

0 comments on commit b2cbba5

Please sign in to comment.