DatabaseClusterProps
- class aws_cdk.aws_neptune_alpha.DatabaseClusterProps(*, instance_type, vpc, associated_roles=None, auto_minor_version_upgrade=None, backup_retention=None, cloudwatch_logs_exports=None, cloudwatch_logs_retention=None, cloudwatch_logs_retention_role=None, cluster_parameter_group=None, copy_tags_to_snapshot=None, db_cluster_name=None, deletion_protection=None, engine_version=None, iam_authentication=None, instance_identifier_base=None, instances=None, kms_key=None, parameter_group=None, port=None, preferred_backup_window=None, preferred_maintenance_window=None, removal_policy=None, security_groups=None, serverless_scaling_configuration=None, storage_encrypted=None, subnet_group=None, vpc_subnets=None)
Bases:
object
(experimental) Properties for a new database cluster.
- Parameters:
instance_type (
InstanceType
) – (experimental) What type of instance to start for the replicas.vpc (
IVpc
) – (experimental) What subnets to run the Neptune instances in. Must be at least 2 subnets in two different AZs.associated_roles (
Optional
[Sequence
[IRole
]]) – (experimental) A list of AWS Identity and Access Management (IAM) role that can be used by the cluster to access other AWS services. Default: - No role is attached to the cluster.auto_minor_version_upgrade (
Optional
[bool
]) – (experimental) If set to true, Neptune will automatically update the engine of the entire cluster to the latest minor version after a stabilization window of 2 to 3 weeks. Default: - falsebackup_retention (
Optional
[Duration
]) – (experimental) How many days to retain the backup. Default: - cdk.Duration.days(1)cloudwatch_logs_exports (
Optional
[Sequence
[LogType
]]) – (experimental) The list of log types that need to be enabled for exporting to CloudWatch Logs. Default: - no log exportscloudwatch_logs_retention (
Optional
[RetentionDays
]) – (experimental) The number of days log events are kept in CloudWatch Logs. When updating this property, unsetting it doesn’t remove the log retention policy. To remove the retention policy, set the value toInfinity
. Default: - logs never expirecloudwatch_logs_retention_role (
Optional
[IRole
]) – (experimental) The IAM role for the Lambda function associated with the custom resource that sets the retention policy. Default: - a new role is created.cluster_parameter_group (
Optional
[IClusterParameterGroup
]) – (experimental) Additional parameters to pass to the database engine. Default: - No parameter group.copy_tags_to_snapshot (
Optional
[bool
]) – (experimental) Whether to copy tags to the snapshot when a snapshot is created. Default: - falsedb_cluster_name (
Optional
[str
]) – (experimental) An optional identifier for the cluster. Default: - A name is automatically generated.deletion_protection (
Optional
[bool
]) – (experimental) Indicates whether the DB cluster should have deletion protection enabled. Default: - true ifremovalPolicy
is RETAIN, false otherwiseengine_version (
Optional
[EngineVersion
]) – (experimental) What version of the database to start. Default: - The default engine version.iam_authentication (
Optional
[bool
]) – (experimental) Map AWS Identity and Access Management (IAM) accounts to database accounts. Default: -false
instance_identifier_base (
Optional
[str
]) – (experimental) Base identifier for instances. Every replica is named by appending the replica number to this string, 1-based. Default: -dbClusterName
is used with the word “Instance” appended. IfdbClusterName
is not provided, the identifier is automatically generated.instances (
Union
[int
,float
,None
]) – (experimental) Number of Neptune compute instances. Default: 1kms_key (
Optional
[IKey
]) – (experimental) The KMS key for storage encryption. Default: - default master key.parameter_group (
Optional
[IParameterGroup
]) – (experimental) The DB parameter group to associate with the instance. Default: no parameter groupport (
Union
[int
,float
,None
]) – (experimental) The port number on which the DB instances in the DB cluster accept connections. Default: 8182preferred_backup_window (
Optional
[str
]) – (experimental) A daily time range in 24-hours UTC format in which backups preferably execute. Must be at least 30 minutes long. Example: ‘01:00-02:00’ Default: - a 30-minute window selected at random from an 8-hour block of time for each AWS Region. To see the time blocks available, seepreferred_maintenance_window (
Optional
[str
]) – (experimental) A weekly time range in which maintenance should preferably execute. Must be at least 30 minutes long. Example: ‘tue:04:17-tue:04:47’ Default: - 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.removal_policy (
Optional
[RemovalPolicy
]) – (experimental) The removal policy to apply when the cluster and its instances are removed or replaced during a stack update, or when the stack is deleted. This removal policy also applies to the implicit security group created for the cluster if one is not supplied as a parameter. Default: - Retain cluster.security_groups (
Optional
[Sequence
[ISecurityGroup
]]) – (experimental) Security group. Default: a new security group is created.serverless_scaling_configuration (
Union
[ServerlessScalingConfiguration
,Dict
[str
,Any
],None
]) – (experimental) Specify minimum and maximum NCUs capacity for a serverless cluster. See https://docs.aws.amazon.com/neptune/latest/userguide/neptune-serverless-capacity-scaling.html Default: - required if instanceType is db.serverlessstorage_encrypted (
Optional
[bool
]) – (experimental) Whether to enable storage encryption. Default: truesubnet_group (
Optional
[ISubnetGroup
]) – (experimental) Existing subnet group for the cluster. Default: - a new subnet group will be created.vpc_subnets (
Union
[SubnetSelection
,Dict
[str
,Any
],None
]) – (experimental) Where to place the instances within the VPC. Default: private subnets
- Stability:
experimental
- ExampleMetadata:
infused
Example:
cluster = neptune.DatabaseCluster(self, "ServerlessDatabase", vpc=vpc, instance_type=neptune.InstanceType.SERVERLESS, serverless_scaling_configuration=neptune.ServerlessScalingConfiguration( min_capacity=1, max_capacity=5 ) )
Attributes
- associated_roles
(experimental) A list of AWS Identity and Access Management (IAM) role that can be used by the cluster to access other AWS services.
- Default:
No role is attached to the cluster.
- Stability:
experimental
- auto_minor_version_upgrade
(experimental) If set to true, Neptune will automatically update the engine of the entire cluster to the latest minor version after a stabilization window of 2 to 3 weeks.
- Default:
false
- Stability:
experimental
- backup_retention
(experimental) How many days to retain the backup.
- Default:
cdk.Duration.days(1)
- Stability:
experimental
- cloudwatch_logs_exports
(experimental) The list of log types that need to be enabled for exporting to CloudWatch Logs.
- Default:
no log exports
- See:
https://docs.aws.amazon.com/neptune/latest/userguide/auditing.html#auditing-enable
- Stability:
experimental
- cloudwatch_logs_retention
(experimental) The number of days log events are kept in CloudWatch Logs.
When updating this property, unsetting it doesn’t remove the log retention policy. To remove the retention policy, set the value to
Infinity
.- Default:
logs never expire
- Stability:
experimental
- cloudwatch_logs_retention_role
(experimental) The IAM role for the Lambda function associated with the custom resource that sets the retention policy.
- Default:
a new role is created.
- Stability:
experimental
- cluster_parameter_group
(experimental) Additional parameters to pass to the database engine.
- Default:
No parameter group.
- Stability:
experimental
- copy_tags_to_snapshot
(experimental) Whether to copy tags to the snapshot when a snapshot is created.
- Default:
false
- Stability:
experimental
- db_cluster_name
(experimental) An optional identifier for the cluster.
- Default:
A name is automatically generated.
- Stability:
experimental
- deletion_protection
(experimental) Indicates whether the DB cluster should have deletion protection enabled.
- Default:
true if
removalPolicy
is RETAIN, false otherwise
- Stability:
experimental
- engine_version
(experimental) What version of the database to start.
- Default:
The default engine version.
- Stability:
experimental
- iam_authentication
(experimental) Map AWS Identity and Access Management (IAM) accounts to database accounts.
- Default:
false
- Stability:
experimental
- instance_identifier_base
(experimental) Base identifier for instances.
Every replica is named by appending the replica number to this string, 1-based.
- Default:
dbClusterName
is used with the word “Instance” appended. IfdbClusterName
is not provided, the
identifier is automatically generated.
- Stability:
experimental
- instance_type
(experimental) What type of instance to start for the replicas.
- Stability:
experimental
- instances
(experimental) Number of Neptune compute instances.
- Default:
1
- Stability:
experimental
- kms_key
(experimental) The KMS key for storage encryption.
- Default:
default master key.
- Stability:
experimental
- parameter_group
(experimental) The DB parameter group to associate with the instance.
- Default:
no parameter group
- Stability:
experimental
- port
(experimental) The port number on which the DB instances in the DB cluster accept connections.
- Default:
8182
- Stability:
experimental
- preferred_backup_window
(experimental) A daily time range in 24-hours UTC format in which backups preferably execute.
Must be at least 30 minutes long.
Example: ‘01:00-02:00’
- Default:
a 30-minute window selected at random from an 8-hour block of
time for each AWS Region. To see the time blocks available, see
- Stability:
experimental
- preferred_maintenance_window
(experimental) A weekly time range in which maintenance should preferably execute.
Must be at least 30 minutes long.
Example: ‘tue:04:17-tue:04:47’
- Default:
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.
- Stability:
experimental
- removal_policy
(experimental) The removal policy to apply when the cluster and its instances are removed or replaced during a stack update, or when the stack is deleted.
This removal policy also applies to the implicit security group created for the cluster if one is not supplied as a parameter.
- Default:
Retain cluster.
- Stability:
experimental
- security_groups
(experimental) Security group.
- Default:
a new security group is created.
- Stability:
experimental
- serverless_scaling_configuration
(experimental) Specify minimum and maximum NCUs capacity for a serverless cluster.
See https://docs.aws.amazon.com/neptune/latest/userguide/neptune-serverless-capacity-scaling.html
- Default:
required if instanceType is db.serverless
- Stability:
experimental
- storage_encrypted
(experimental) Whether to enable storage encryption.
- Default:
true
- Stability:
experimental
- subnet_group
(experimental) Existing subnet group for the cluster.
- Default:
a new subnet group will be created.
- Stability:
experimental
- vpc
(experimental) What subnets to run the Neptune instances in.
Must be at least 2 subnets in two different AZs.
- Stability:
experimental
- vpc_subnets
(experimental) Where to place the instances within the VPC.
- Default:
private subnets
- Stability:
experimental