java.lang.Object
software.amazon.jsii.JsiiObject
All Implemented Interfaces:
IConstruct, IDependable, IInspectable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:29:56.416Z") @Stability(Stable) public class CfnCluster extends CfnResource implements IInspectable
A CloudFormation AWS::DocDBElastic::Cluster.

Creates a new Amazon DocumentDB elastic cluster and returns its cluster structure.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.docdbelastic.*;
 CfnCluster cfnCluster = CfnCluster.Builder.create(this, "MyCfnCluster")
         .adminUserName("adminUserName")
         .authType("authType")
         .clusterName("clusterName")
         .shardCapacity(123)
         .shardCount(123)
         // the properties below are optional
         .adminUserPassword("adminUserPassword")
         .kmsKeyId("kmsKeyId")
         .preferredMaintenanceWindow("preferredMaintenanceWindow")
         .subnetIds(List.of("subnetIds"))
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .vpcSecurityGroupIds(List.of("vpcSecurityGroupIds"))
         .build();
 
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnCluster

      protected CfnCluster(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnCluster

      protected CfnCluster(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnCluster

      @Stability(Stable) public CfnCluster(@NotNull Construct scope, @NotNull String id, @NotNull CfnClusterProps props)
      Create a new AWS::DocDBElastic::Cluster.

      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
      props -
      • resource properties.
      This parameter is required.
  • Method Details

    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector -
      • tree inspector to collect and process attributes.
      This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrClusterArn

      @Stability(Stable) @NotNull public String getAttrClusterArn()
    • getAttrClusterEndpoint

      @Stability(Stable) @NotNull public String getAttrClusterEndpoint()
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getTags

      @Stability(Stable) @NotNull public TagManager getTags()
      The tags to be assigned to the new elastic cluster.
    • getAdminUserName

      @Stability(Stable) @NotNull public String getAdminUserName()
      The name of the Amazon DocumentDB elastic clusters administrator.

      Constraints :

      • Must be from 1 to 63 letters or numbers.
      • The first character must be a letter.
      • Cannot be a reserved word.
    • setAdminUserName

      @Stability(Stable) public void setAdminUserName(@NotNull String value)
      The name of the Amazon DocumentDB elastic clusters administrator.

      Constraints :

      • Must be from 1 to 63 letters or numbers.
      • The first character must be a letter.
      • Cannot be a reserved word.
    • getAuthType

      @Stability(Stable) @NotNull public String getAuthType()
      The authentication type used to determine where to fetch the password used for accessing the elastic cluster.

      Valid types are PLAIN_TEXT or SECRET_ARN .

    • setAuthType

      @Stability(Stable) public void setAuthType(@NotNull String value)
      The authentication type used to determine where to fetch the password used for accessing the elastic cluster.

      Valid types are PLAIN_TEXT or SECRET_ARN .

    • getClusterName

      @Stability(Stable) @NotNull public String getClusterName()
      The name of the new elastic cluster. This parameter is stored as a lowercase string.

      Constraints :

      • Must contain from 1 to 63 letters, numbers, or hyphens.
      • The first character must be a letter.
      • Cannot end with a hyphen or contain two consecutive hyphens.

      Example : my-cluster

    • setClusterName

      @Stability(Stable) public void setClusterName(@NotNull String value)
      The name of the new elastic cluster. This parameter is stored as a lowercase string.

      Constraints :

      • Must contain from 1 to 63 letters, numbers, or hyphens.
      • The first character must be a letter.
      • Cannot end with a hyphen or contain two consecutive hyphens.

      Example : my-cluster

    • getShardCapacity

      @Stability(Stable) @NotNull public Number getShardCapacity()
      The number of vCPUs assigned to each elastic cluster shard.

      Maximum is 64. Allowed values are 2, 4, 8, 16, 32, 64.

    • setShardCapacity

      @Stability(Stable) public void setShardCapacity(@NotNull Number value)
      The number of vCPUs assigned to each elastic cluster shard.

      Maximum is 64. Allowed values are 2, 4, 8, 16, 32, 64.

    • getShardCount

      @Stability(Stable) @NotNull public Number getShardCount()
      The number of shards assigned to the elastic cluster.

      Maximum is 32.

    • setShardCount

      @Stability(Stable) public void setShardCount(@NotNull Number value)
      The number of shards assigned to the elastic cluster.

      Maximum is 32.

    • getAdminUserPassword

      @Stability(Stable) @Nullable public String getAdminUserPassword()
      The password for the Elastic DocumentDB cluster administrator and can contain any printable ASCII characters.

      Constraints :

      • Must contain from 8 to 100 characters.
      • Cannot contain a forward slash (/), double quote ("), or the "at" symbol (@).
      • A valid AdminUserName entry is also required.
    • setAdminUserPassword

      @Stability(Stable) public void setAdminUserPassword(@Nullable String value)
      The password for the Elastic DocumentDB cluster administrator and can contain any printable ASCII characters.

      Constraints :

      • Must contain from 8 to 100 characters.
      • Cannot contain a forward slash (/), double quote ("), or the "at" symbol (@).
      • A valid AdminUserName entry is also required.
    • getKmsKeyId

      @Stability(Stable) @Nullable public String getKmsKeyId()
      The KMS key identifier to use to encrypt the new elastic cluster.

      The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are creating a cluster using the same Amazon account that owns this KMS encryption key, you can use the KMS key alias instead of the ARN as the KMS encryption key.

      If an encryption key is not specified, Amazon DocumentDB uses the default encryption key that KMS creates for your account. Your account has a different default encryption key for each Amazon Region.

    • setKmsKeyId

      @Stability(Stable) public void setKmsKeyId(@Nullable String value)
      The KMS key identifier to use to encrypt the new elastic cluster.

      The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are creating a cluster using the same Amazon account that owns this KMS encryption key, you can use the KMS key alias instead of the ARN as the KMS encryption key.

      If an encryption key is not specified, Amazon DocumentDB uses the default encryption key that KMS creates for your account. Your account has a different default encryption key for each Amazon Region.

    • getPreferredMaintenanceWindow

      @Stability(Stable) @Nullable public String getPreferredMaintenanceWindow()
      The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).

      Format : ddd:hh24:mi-ddd:hh24:mi

      Default : a 30-minute window selected at random from an 8-hour block of time for each AWS Region , occurring on a random day of the week.

      Valid days : Mon, Tue, Wed, Thu, Fri, Sat, Sun

      Constraints : Minimum 30-minute window.

    • setPreferredMaintenanceWindow

      @Stability(Stable) public void setPreferredMaintenanceWindow(@Nullable String value)
      The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).

      Format : ddd:hh24:mi-ddd:hh24:mi

      Default : a 30-minute window selected at random from an 8-hour block of time for each AWS Region , occurring on a random day of the week.

      Valid days : Mon, Tue, Wed, Thu, Fri, Sat, Sun

      Constraints : Minimum 30-minute window.

    • getSubnetIds

      @Stability(Stable) @Nullable public List<String> getSubnetIds()
      The Amazon EC2 subnet IDs for the new elastic cluster.
    • setSubnetIds

      @Stability(Stable) public void setSubnetIds(@Nullable List<String> value)
      The Amazon EC2 subnet IDs for the new elastic cluster.
    • getVpcSecurityGroupIds

      @Stability(Stable) @Nullable public List<String> getVpcSecurityGroupIds()
      A list of EC2 VPC security groups to associate with the new elastic cluster.
    • setVpcSecurityGroupIds

      @Stability(Stable) public void setVpcSecurityGroupIds(@Nullable List<String> value)
      A list of EC2 VPC security groups to associate with the new elastic cluster.