Skip to content
v2.275.0

DatabaseClusterAttributes Struct ​

Properties that describe an existing cluster instance.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_docdb as docdb } from 'aws-cdk-lib';
import { aws_ec2 as ec2 } from 'aws-cdk-lib';

declare const securityGroup: ec2.SecurityGroup;
const databaseClusterAttributes: docdb.DatabaseClusterAttributes = {
  clusterIdentifier: 'clusterIdentifier',

  // the properties below are optional
  clusterEndpointAddress: 'clusterEndpointAddress',
  instanceEndpointAddresses: ['instanceEndpointAddresses'],
  instanceIdentifiers: ['instanceIdentifiers'],
  port: 123,
  readerEndpointAddress: 'readerEndpointAddress',
  securityGroup: securityGroup,
};

Properties ​

clusterEndpointAddressoptionalstringcluster_endpoint_addressoptionalstrclusterEndpointAddressoptionalStringClusterEndpointAddressoptionalstringClusterEndpointAddressoptional*string#
Cluster endpoint address.

Default: no cluster endpoint address

clusterIdentifierstringcluster_identifierstrclusterIdentifierStringClusterIdentifierstringClusterIdentifier*stringrequired#
Identifier for the cluster.
instanceEndpointAddressesoptionalstring[]instance_endpoint_addressesoptionaltyping.List[str]instanceEndpointAddressesoptionalList<String>InstanceEndpointAddressesoptionalstring[]InstanceEndpointAddressesoptional*[]*string#
Endpoint addresses of individual instances.

Default: no instance endpoint addresses

instanceIdentifiersoptionalstring[]instance_identifiersoptionaltyping.List[str]instanceIdentifiersoptionalList<String>InstanceIdentifiersoptionalstring[]InstanceIdentifiersoptional*[]*string#
Identifier for the instances.

Default: no instance identifiers

portoptionalnumberportoptionalint | floatportoptionalNumberPortoptionaldoublePortoptional*float64= none#
The database port.
readerEndpointAddressoptionalstringreader_endpoint_addressoptionalstrreaderEndpointAddressoptionalStringReaderEndpointAddressoptionalstringReaderEndpointAddressoptional*string#
Reader endpoint address.

Default: no reader endpoint address

securityGroupoptionalISecurityGroupsecurity_groupoptionalISecurityGroupsecurityGroupoptionalISecurityGroupSecurityGroupoptionalISecurityGroupSecurityGroupoptionalISecurityGroup#
The security group of the database cluster.

Default: no security groups