Class DBCluster
- java.lang.Object
-
- software.amazon.awssdk.services.docdb.model.DBCluster
-
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<DBCluster.Builder,DBCluster>
@Generated("software.amazon.awssdk:codegen") public final class DBCluster extends Object implements SdkPojo, Serializable, ToCopyableBuilder<DBCluster.Builder,DBCluster>
Detailed information about a cluster.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceDBCluster.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description List<DBClusterRole>associatedRoles()Provides a list of the Identity and Access Management (IAM) roles that are associated with the cluster.List<String>availabilityZones()Provides the list of Amazon EC2 Availability Zones that instances in the cluster can be created in.IntegerbackupRetentionPeriod()Specifies the number of days for which automatic snapshots are retained.static DBCluster.Builderbuilder()StringcloneGroupId()Identifies the clone group to which the DB cluster is associated.InstantclusterCreateTime()Specifies the time when the cluster was created, in Universal Coordinated Time (UTC).StringdbClusterArn()The Amazon Resource Name (ARN) for the cluster.StringdbClusterIdentifier()Contains a user-supplied cluster identifier.List<DBClusterMember>dbClusterMembers()Provides the list of instances that make up the cluster.StringdbClusterParameterGroup()Specifies the name of the cluster parameter group for the cluster.StringdbClusterResourceId()The Amazon Web Services Region-unique, immutable identifier for the cluster.StringdbSubnetGroup()Specifies information on the subnet group that is associated with the cluster, including the name, description, and subnets in the subnet group.BooleandeletionProtection()Specifies whether this cluster can be deleted.InstantearliestRestorableTime()The earliest time to which a database can be restored with point-in-time restore.List<String>enabledCloudwatchLogsExports()A list of log types that this cluster is configured to export to Amazon CloudWatch Logs.Stringendpoint()Specifies the connection endpoint for the primary instance of the cluster.Stringengine()Provides the name of the database engine to be used for this cluster.StringengineVersion()Indicates the database engine version.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)booleanhasAssociatedRoles()For responses, this returns true if the service returned a value for the AssociatedRoles property.booleanhasAvailabilityZones()For responses, this returns true if the service returned a value for the AvailabilityZones property.booleanhasDbClusterMembers()For responses, this returns true if the service returned a value for the DBClusterMembers property.booleanhasEnabledCloudwatchLogsExports()For responses, this returns true if the service returned a value for the EnabledCloudwatchLogsExports property.inthashCode()booleanhasReadReplicaIdentifiers()For responses, this returns true if the service returned a value for the ReadReplicaIdentifiers property.booleanhasVpcSecurityGroups()For responses, this returns true if the service returned a value for the VpcSecurityGroups property.StringhostedZoneId()Specifies the ID that Amazon Route 53 assigns when you create a hosted zone.StringkmsKeyId()IfStorageEncryptedistrue, the KMS key identifier for the encrypted cluster.InstantlatestRestorableTime()Specifies the latest time to which a database can be restored with point-in-time restore.StringmasterUsername()Contains the master user name for the cluster.BooleanmultiAZ()Specifies whether the cluster has instances in multiple Availability Zones.StringpercentProgress()Specifies the progress of the operation as a percentage.Integerport()Specifies the port that the database engine is listening on.StringpreferredBackupWindow()Specifies the daily time range during which automated backups are created if automated backups are enabled, as determined by theBackupRetentionPeriod.StringpreferredMaintenanceWindow()Specifies the weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).StringreaderEndpoint()The reader endpoint for the cluster.List<String>readReplicaIdentifiers()Contains one or more identifiers of the secondary clusters that are associated with this cluster.StringreplicationSourceIdentifier()Contains the identifier of the source cluster if this cluster is a secondary cluster.List<SdkField<?>>sdkFields()static Class<? extends DBCluster.Builder>serializableBuilderClass()Stringstatus()Specifies the current state of this cluster.BooleanstorageEncrypted()Specifies whether the cluster is encrypted.StringstorageType()Storage type associated with your clusterDBCluster.BuildertoBuilder()StringtoString()Returns a string representation of this object.List<VpcSecurityGroupMembership>vpcSecurityGroups()Provides a list of virtual private cloud (VPC) security groups that the cluster belongs to.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
hasAvailabilityZones
public final boolean hasAvailabilityZones()
For responses, this returns true if the service returned a value for the AvailabilityZones property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
availabilityZones
public final List<String> availabilityZones()
Provides the list of Amazon EC2 Availability Zones that instances in the cluster can be created in.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasAvailabilityZones()method.- Returns:
- Provides the list of Amazon EC2 Availability Zones that instances in the cluster can be created in.
-
backupRetentionPeriod
public final Integer backupRetentionPeriod()
Specifies the number of days for which automatic snapshots are retained.
- Returns:
- Specifies the number of days for which automatic snapshots are retained.
-
dbClusterIdentifier
public final String dbClusterIdentifier()
Contains a user-supplied cluster identifier. This identifier is the unique key that identifies a cluster.
- Returns:
- Contains a user-supplied cluster identifier. This identifier is the unique key that identifies a cluster.
-
dbClusterParameterGroup
public final String dbClusterParameterGroup()
Specifies the name of the cluster parameter group for the cluster.
- Returns:
- Specifies the name of the cluster parameter group for the cluster.
-
dbSubnetGroup
public final String dbSubnetGroup()
Specifies information on the subnet group that is associated with the cluster, including the name, description, and subnets in the subnet group.
- Returns:
- Specifies information on the subnet group that is associated with the cluster, including the name, description, and subnets in the subnet group.
-
status
public final String status()
Specifies the current state of this cluster.
- Returns:
- Specifies the current state of this cluster.
-
percentProgress
public final String percentProgress()
Specifies the progress of the operation as a percentage.
- Returns:
- Specifies the progress of the operation as a percentage.
-
earliestRestorableTime
public final Instant earliestRestorableTime()
The earliest time to which a database can be restored with point-in-time restore.
- Returns:
- The earliest time to which a database can be restored with point-in-time restore.
-
endpoint
public final String endpoint()
Specifies the connection endpoint for the primary instance of the cluster.
- Returns:
- Specifies the connection endpoint for the primary instance of the cluster.
-
readerEndpoint
public final String readerEndpoint()
The reader endpoint for the cluster. The reader endpoint for a cluster load balances connections across the Amazon DocumentDB replicas that are available in a cluster. As clients request new connections to the reader endpoint, Amazon DocumentDB distributes the connection requests among the Amazon DocumentDB replicas in the cluster. This functionality can help balance your read workload across multiple Amazon DocumentDB replicas in your cluster.
If a failover occurs, and the Amazon DocumentDB replica that you are connected to is promoted to be the primary instance, your connection is dropped. To continue sending your read workload to other Amazon DocumentDB replicas in the cluster, you can then reconnect to the reader endpoint.
- Returns:
- The reader endpoint for the cluster. The reader endpoint for a cluster load balances connections across
the Amazon DocumentDB replicas that are available in a cluster. As clients request new connections to the
reader endpoint, Amazon DocumentDB distributes the connection requests among the Amazon DocumentDB
replicas in the cluster. This functionality can help balance your read workload across multiple Amazon
DocumentDB replicas in your cluster.
If a failover occurs, and the Amazon DocumentDB replica that you are connected to is promoted to be the primary instance, your connection is dropped. To continue sending your read workload to other Amazon DocumentDB replicas in the cluster, you can then reconnect to the reader endpoint.
-
multiAZ
public final Boolean multiAZ()
Specifies whether the cluster has instances in multiple Availability Zones.
- Returns:
- Specifies whether the cluster has instances in multiple Availability Zones.
-
engine
public final String engine()
Provides the name of the database engine to be used for this cluster.
- Returns:
- Provides the name of the database engine to be used for this cluster.
-
engineVersion
public final String engineVersion()
Indicates the database engine version.
- Returns:
- Indicates the database engine version.
-
latestRestorableTime
public final Instant latestRestorableTime()
Specifies the latest time to which a database can be restored with point-in-time restore.
- Returns:
- Specifies the latest time to which a database can be restored with point-in-time restore.
-
port
public final Integer port()
Specifies the port that the database engine is listening on.
- Returns:
- Specifies the port that the database engine is listening on.
-
masterUsername
public final String masterUsername()
Contains the master user name for the cluster.
- Returns:
- Contains the master user name for the cluster.
-
preferredBackupWindow
public final String preferredBackupWindow()
Specifies the daily time range during which automated backups are created if automated backups are enabled, as determined by the
BackupRetentionPeriod.- Returns:
- Specifies the daily time range during which automated backups are created if automated backups are
enabled, as determined by the
BackupRetentionPeriod.
-
preferredMaintenanceWindow
public final String preferredMaintenanceWindow()
Specifies the weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).
- Returns:
- Specifies the weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).
-
replicationSourceIdentifier
public final String replicationSourceIdentifier()
Contains the identifier of the source cluster if this cluster is a secondary cluster.
- Returns:
- Contains the identifier of the source cluster if this cluster is a secondary cluster.
-
hasReadReplicaIdentifiers
public final boolean hasReadReplicaIdentifiers()
For responses, this returns true if the service returned a value for the ReadReplicaIdentifiers property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
readReplicaIdentifiers
public final List<String> readReplicaIdentifiers()
Contains one or more identifiers of the secondary clusters that are associated with this cluster.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasReadReplicaIdentifiers()method.- Returns:
- Contains one or more identifiers of the secondary clusters that are associated with this cluster.
-
hasDbClusterMembers
public final boolean hasDbClusterMembers()
For responses, this returns true if the service returned a value for the DBClusterMembers property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
dbClusterMembers
public final List<DBClusterMember> dbClusterMembers()
Provides the list of instances that make up the cluster.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasDbClusterMembers()method.- Returns:
- Provides the list of instances that make up the cluster.
-
hasVpcSecurityGroups
public final boolean hasVpcSecurityGroups()
For responses, this returns true if the service returned a value for the VpcSecurityGroups property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
vpcSecurityGroups
public final List<VpcSecurityGroupMembership> vpcSecurityGroups()
Provides a list of virtual private cloud (VPC) security groups that the cluster belongs to.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasVpcSecurityGroups()method.- Returns:
- Provides a list of virtual private cloud (VPC) security groups that the cluster belongs to.
-
hostedZoneId
public final String hostedZoneId()
Specifies the ID that Amazon Route 53 assigns when you create a hosted zone.
- Returns:
- Specifies the ID that Amazon Route 53 assigns when you create a hosted zone.
-
storageEncrypted
public final Boolean storageEncrypted()
Specifies whether the cluster is encrypted.
- Returns:
- Specifies whether the cluster is encrypted.
-
kmsKeyId
public final String kmsKeyId()
If
StorageEncryptedistrue, the KMS key identifier for the encrypted cluster.- Returns:
- If
StorageEncryptedistrue, the KMS key identifier for the encrypted cluster.
-
dbClusterResourceId
public final String dbClusterResourceId()
The Amazon Web Services Region-unique, immutable identifier for the cluster. This identifier is found in CloudTrail log entries whenever the KMS key for the cluster is accessed.
- Returns:
- The Amazon Web Services Region-unique, immutable identifier for the cluster. This identifier is found in CloudTrail log entries whenever the KMS key for the cluster is accessed.
-
dbClusterArn
public final String dbClusterArn()
The Amazon Resource Name (ARN) for the cluster.
- Returns:
- The Amazon Resource Name (ARN) for the cluster.
-
hasAssociatedRoles
public final boolean hasAssociatedRoles()
For responses, this returns true if the service returned a value for the AssociatedRoles property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
associatedRoles
public final List<DBClusterRole> associatedRoles()
Provides a list of the Identity and Access Management (IAM) roles that are associated with the cluster. (IAM) roles that are associated with a cluster grant permission for the cluster to access other Amazon Web Services services on your behalf.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasAssociatedRoles()method.- Returns:
- Provides a list of the Identity and Access Management (IAM) roles that are associated with the cluster. (IAM) roles that are associated with a cluster grant permission for the cluster to access other Amazon Web Services services on your behalf.
-
cloneGroupId
public final String cloneGroupId()
Identifies the clone group to which the DB cluster is associated.
- Returns:
- Identifies the clone group to which the DB cluster is associated.
-
clusterCreateTime
public final Instant clusterCreateTime()
Specifies the time when the cluster was created, in Universal Coordinated Time (UTC).
- Returns:
- Specifies the time when the cluster was created, in Universal Coordinated Time (UTC).
-
hasEnabledCloudwatchLogsExports
public final boolean hasEnabledCloudwatchLogsExports()
For responses, this returns true if the service returned a value for the EnabledCloudwatchLogsExports property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
enabledCloudwatchLogsExports
public final List<String> enabledCloudwatchLogsExports()
A list of log types that this cluster is configured to export to Amazon CloudWatch Logs.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasEnabledCloudwatchLogsExports()method.- Returns:
- A list of log types that this cluster is configured to export to Amazon CloudWatch Logs.
-
deletionProtection
public final Boolean deletionProtection()
Specifies whether this cluster can be deleted. If
DeletionProtectionis enabled, the cluster cannot be deleted unless it is modified andDeletionProtectionis disabled.DeletionProtectionprotects clusters from being accidentally deleted.- Returns:
- Specifies whether this cluster can be deleted. If
DeletionProtectionis enabled, the cluster cannot be deleted unless it is modified andDeletionProtectionis disabled.DeletionProtectionprotects clusters from being accidentally deleted.
-
storageType
public final String storageType()
Storage type associated with your cluster
Storage type associated with your cluster
For information on storage types for Amazon DocumentDB clusters, see Cluster storage configurations in the Amazon DocumentDB Developer Guide.
Valid values for storage type -
standard | iopt1Default value is
standard- Returns:
- Storage type associated with your cluster
Storage type associated with your cluster
For information on storage types for Amazon DocumentDB clusters, see Cluster storage configurations in the Amazon DocumentDB Developer Guide.
Valid values for storage type -
standard | iopt1Default value is
standard
-
toBuilder
public DBCluster.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<DBCluster.Builder,DBCluster>
-
builder
public static DBCluster.Builder builder()
-
serializableBuilderClass
public static Class<? extends DBCluster.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
-