CfnClusterPropsMixin

class aws_cdk.mixins_preview.aws_dsql.mixins.CfnClusterPropsMixin(props, *, strategy=None)

Bases: Mixin

The AWS::DSQL::Cluster resource specifies an cluster. You can use this resource to create, modify, and manage clusters.

This resource supports both single-Region clusters and multi-Region clusters through the MultiRegionProperties parameter. .. epigraph:

Creating multi-Region clusters requires additional IAM permissions beyond those needed for single-Region clusters. > - The witness Region specified in ``multiRegionProperties.witnessRegion`` cannot be the same as the cluster's Region.

Required permissions

  • dsql:CreateCluster - Required to create a cluster.

Resources: arn:aws:dsql:region:account-id:cluster/*

  • dsql:TagResource - Permission to add tags to a resource.

Resources: arn:aws:dsql:region:account-id:cluster/*

  • dsql:PutMultiRegionProperties - Permission to configure multi-Region properties for a cluster.

Resources: arn:aws:dsql:region:account-id:cluster/*

  • dsql:AddPeerCluster - When specifying multiRegionProperties.clusters , permission to add peer clusters.

Resources:

  • Local cluster: arn:aws:dsql:region:account-id:cluster/*

  • Each peer cluster: exact ARN of each specified peer cluster

  • dsql:PutWitnessRegion - When specifying multiRegionProperties.witnessRegion , permission to set a witness Region. This permission is checked both in the cluster Region and in the witness Region.

Resources: arn:aws:dsql:region:account-id:cluster/*

Condition Keys: dsql:WitnessRegion (matching the specified witness region)

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dsql-cluster.html

CloudformationResource:

AWS::DSQL::Cluster

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_dsql import mixins as dsql_mixins

cfn_cluster_props_mixin = dsql_mixins.CfnClusterPropsMixin(dsql_mixins.CfnClusterMixinProps(
    deletion_protection_enabled=False,
    kms_encryption_key="kmsEncryptionKey",
    multi_region_properties=dsql_mixins.CfnClusterPropsMixin.MultiRegionPropertiesProperty(
        clusters=["clusters"],
        witness_region="witnessRegion"
    ),
    policy_document="policyDocument",
    tags=[CfnTag(
        key="key",
        value="value"
    )]
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::DSQL::Cluster.

Parameters:
  • props (Union[CfnClusterMixinProps, Dict[str, Any]]) – L1 properties to apply.

  • strategy (Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['deletionProtectionEnabled', 'kmsEncryptionKey', 'multiRegionProperties', 'policyDocument', 'tags']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

EncryptionDetailsProperty

class CfnClusterPropsMixin.EncryptionDetailsProperty(*, encryption_status=None, encryption_type=None, kms_key_arn=None)

Bases: object

Configuration details about encryption for the cluster including the AWS key ARN, encryption type, and encryption status.

Parameters:
  • encryption_status (Optional[str]) – The status of encryption for the cluster.

  • encryption_type (Optional[str]) – The type of encryption that protects the data on your cluster.

  • kms_key_arn (Optional[str]) – The ARN of the AWS key that encrypts data in the cluster.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-encryptiondetails.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_dsql import mixins as dsql_mixins

encryption_details_property = dsql_mixins.CfnClusterPropsMixin.EncryptionDetailsProperty(
    encryption_status="encryptionStatus",
    encryption_type="encryptionType",
    kms_key_arn="kmsKeyArn"
)

Attributes

encryption_status

The status of encryption for the cluster.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-encryptiondetails.html#cfn-dsql-cluster-encryptiondetails-encryptionstatus

encryption_type

The type of encryption that protects the data on your cluster.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-encryptiondetails.html#cfn-dsql-cluster-encryptiondetails-encryptiontype

kms_key_arn

The ARN of the AWS key that encrypts data in the cluster.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-encryptiondetails.html#cfn-dsql-cluster-encryptiondetails-kmskeyarn

MultiRegionPropertiesProperty

class CfnClusterPropsMixin.MultiRegionPropertiesProperty(*, clusters=None, witness_region=None)

Bases: object

Defines the structure for multi-Region cluster configurations, containing the witness Region and peered cluster settings.

Parameters:
  • clusters (Optional[Sequence[str]]) – The set of peered clusters that form the multi-Region cluster configuration. Each peered cluster represents a database instance in a different Region.

  • witness_region (Optional[str]) – The Region that serves as the witness Region for a multi-Region cluster. The witness Region helps maintain cluster consistency and quorum.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-multiregionproperties.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_dsql import mixins as dsql_mixins

multi_region_properties_property = dsql_mixins.CfnClusterPropsMixin.MultiRegionPropertiesProperty(
    clusters=["clusters"],
    witness_region="witnessRegion"
)

Attributes

clusters

The set of peered clusters that form the multi-Region cluster configuration.

Each peered cluster represents a database instance in a different Region.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-multiregionproperties.html#cfn-dsql-cluster-multiregionproperties-clusters

witness_region

The Region that serves as the witness Region for a multi-Region cluster.

The witness Region helps maintain cluster consistency and quorum.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dsql-cluster-multiregionproperties.html#cfn-dsql-cluster-multiregionproperties-witnessregion