Class CfnDatabaseMixinProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnDatabaseMixinProps>
- Enclosing interface:
CfnDatabaseMixinProps
CfnDatabaseMixinProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionavailabilityZone(String availabilityZone) Sets the value ofCfnDatabaseMixinProps.getAvailabilityZone()backupRetention(Boolean backupRetention) Sets the value ofCfnDatabaseMixinProps.getBackupRetention()backupRetention(IResolvable backupRetention) Sets the value ofCfnDatabaseMixinProps.getBackupRetention()build()Builds the configured instance.caCertificateIdentifier(String caCertificateIdentifier) Sets the value ofCfnDatabaseMixinProps.getCaCertificateIdentifier()masterDatabaseName(String masterDatabaseName) Sets the value ofCfnDatabaseMixinProps.getMasterDatabaseName()masterUsername(String masterUsername) Sets the value ofCfnDatabaseMixinProps.getMasterUsername()masterUserPassword(String masterUserPassword) Sets the value ofCfnDatabaseMixinProps.getMasterUserPassword()preferredBackupWindow(String preferredBackupWindow) Sets the value ofCfnDatabaseMixinProps.getPreferredBackupWindow()preferredMaintenanceWindow(String preferredMaintenanceWindow) Sets the value ofCfnDatabaseMixinProps.getPreferredMaintenanceWindow()publiclyAccessible(Boolean publiclyAccessible) Sets the value ofCfnDatabaseMixinProps.getPubliclyAccessible()publiclyAccessible(IResolvable publiclyAccessible) Sets the value ofCfnDatabaseMixinProps.getPubliclyAccessible()relationalDatabaseBlueprintId(String relationalDatabaseBlueprintId) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseBlueprintId()relationalDatabaseBundleId(String relationalDatabaseBundleId) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseBundleId()relationalDatabaseName(String relationalDatabaseName) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseName()relationalDatabaseParameters(List<? extends Object> relationalDatabaseParameters) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseParameters()relationalDatabaseParameters(IResolvable relationalDatabaseParameters) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseParameters()rotateMasterUserPassword(Boolean rotateMasterUserPassword) Sets the value ofCfnDatabaseMixinProps.getRotateMasterUserPassword()rotateMasterUserPassword(IResolvable rotateMasterUserPassword) Sets the value ofCfnDatabaseMixinProps.getRotateMasterUserPassword()Sets the value ofCfnDatabaseMixinProps.getTags()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
availabilityZone
Sets the value ofCfnDatabaseMixinProps.getAvailabilityZone()- Parameters:
availabilityZone- The Availability Zone for the database.- Returns:
this
-
backupRetention
Sets the value ofCfnDatabaseMixinProps.getBackupRetention()- Parameters:
backupRetention- A Boolean value indicating whether automated backup retention is enabled for the database. Data Import Mode is enabled whenBackupRetentionis set tofalse, and is disabled whenBackupRetentionis set totrue.- Returns:
this
-
backupRetention
@Stability(Stable) public CfnDatabaseMixinProps.Builder backupRetention(IResolvable backupRetention) Sets the value ofCfnDatabaseMixinProps.getBackupRetention()- Parameters:
backupRetention- A Boolean value indicating whether automated backup retention is enabled for the database. Data Import Mode is enabled whenBackupRetentionis set tofalse, and is disabled whenBackupRetentionis set totrue.- Returns:
this
-
caCertificateIdentifier
@Stability(Stable) public CfnDatabaseMixinProps.Builder caCertificateIdentifier(String caCertificateIdentifier) Sets the value ofCfnDatabaseMixinProps.getCaCertificateIdentifier()- Parameters:
caCertificateIdentifier- The certificate associated with the database.- Returns:
this
-
masterDatabaseName
@Stability(Stable) public CfnDatabaseMixinProps.Builder masterDatabaseName(String masterDatabaseName) Sets the value ofCfnDatabaseMixinProps.getMasterDatabaseName()- Parameters:
masterDatabaseName- The meaning of this parameter differs according to the database engine you use. MySQLThe name of the database to create when the Lightsail database resource is created. If this parameter isn't specified, no database is created in the database resource.
Constraints:
- Must contain 1-64 letters or numbers.
- Must begin with a letter. Subsequent characters can be letters, underscores, or numbers (0-9).
- Can't be a word reserved by the specified database engine.
For more information about reserved words in MySQL, see the Keywords and Reserved Words articles for MySQL 5.6 , MySQL 5.7 , and MySQL 8.0 .
PostgreSQL
The name of the database to create when the Lightsail database resource is created. If this parameter isn't specified, a database named
postgresis created in the database resource.Constraints:
- Must contain 1-63 letters or numbers.
- Must begin with a letter. Subsequent characters can be letters, underscores, or numbers (0-9).
- Can't be a word reserved by the specified database engine.
For more information about reserved words in PostgreSQL, see the SQL Key Words articles for PostgreSQL 9.6 , PostgreSQL 10 , PostgreSQL 11 , and PostgreSQL 12 .
- Returns:
this
-
masterUsername
Sets the value ofCfnDatabaseMixinProps.getMasterUsername()- Parameters:
masterUsername- The name for the primary user. MySQLConstraints:
- Required for MySQL.
- Must be 1-16 letters or numbers. Can contain underscores.
- First character must be a letter.
- Can't be a reserved word for the chosen database engine.
For more information about reserved words in MySQL 5.6 or 5.7, see the Keywords and Reserved Words articles for MySQL 5.6 , MySQL 5.7 , or MySQL 8.0 .
PostgreSQL
Constraints:
- Required for PostgreSQL.
- Must be 1-63 letters or numbers. Can contain underscores.
- First character must be a letter.
- Can't be a reserved word for the chosen database engine.
For more information about reserved words in MySQL 5.6 or 5.7, see the Keywords and Reserved Words articles for PostgreSQL 9.6 , PostgreSQL 10 , PostgreSQL 11 , and PostgreSQL 12 .
- Returns:
this
-
masterUserPassword
@Stability(Stable) public CfnDatabaseMixinProps.Builder masterUserPassword(String masterUserPassword) Sets the value ofCfnDatabaseMixinProps.getMasterUserPassword()- Parameters:
masterUserPassword- The password for the primary user of the database. The password can include any printable ASCII character except the following: /, ", or- Returns:
this
-
preferredBackupWindow
@Stability(Stable) public CfnDatabaseMixinProps.Builder preferredBackupWindow(String preferredBackupWindow) Sets the value ofCfnDatabaseMixinProps.getPreferredBackupWindow()- Parameters:
preferredBackupWindow- The daily time range during which automated backups are created for the database (for example,16:00-16:30).- Returns:
this
-
preferredMaintenanceWindow
@Stability(Stable) public CfnDatabaseMixinProps.Builder preferredMaintenanceWindow(String preferredMaintenanceWindow) Sets the value ofCfnDatabaseMixinProps.getPreferredMaintenanceWindow()- Parameters:
preferredMaintenanceWindow- The weekly time range during which system maintenance can occur for the database, formatted as follows:ddd:hh24:mi-ddd:hh24:mi. For example,Tue:17:00-Tue:17:30.- Returns:
this
-
publiclyAccessible
@Stability(Stable) public CfnDatabaseMixinProps.Builder publiclyAccessible(Boolean publiclyAccessible) Sets the value ofCfnDatabaseMixinProps.getPubliclyAccessible()- Parameters:
publiclyAccessible- A Boolean value indicating whether the database is accessible to anyone on the internet.- Returns:
this
-
publiclyAccessible
@Stability(Stable) public CfnDatabaseMixinProps.Builder publiclyAccessible(IResolvable publiclyAccessible) Sets the value ofCfnDatabaseMixinProps.getPubliclyAccessible()- Parameters:
publiclyAccessible- A Boolean value indicating whether the database is accessible to anyone on the internet.- Returns:
this
-
relationalDatabaseBlueprintId
@Stability(Stable) public CfnDatabaseMixinProps.Builder relationalDatabaseBlueprintId(String relationalDatabaseBlueprintId) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseBlueprintId()- Parameters:
relationalDatabaseBlueprintId- The blueprint ID for the database (for example,mysql_8_0).- Returns:
this
-
relationalDatabaseBundleId
@Stability(Stable) public CfnDatabaseMixinProps.Builder relationalDatabaseBundleId(String relationalDatabaseBundleId) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseBundleId()- Parameters:
relationalDatabaseBundleId- The bundle ID for the database (for example,medium_1_0).- Returns:
this
-
relationalDatabaseName
@Stability(Stable) public CfnDatabaseMixinProps.Builder relationalDatabaseName(String relationalDatabaseName) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseName()- Parameters:
relationalDatabaseName- The name of the instance.- Returns:
this
-
relationalDatabaseParameters
@Stability(Stable) public CfnDatabaseMixinProps.Builder relationalDatabaseParameters(IResolvable relationalDatabaseParameters) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseParameters()- Parameters:
relationalDatabaseParameters- An array of parameters for the database.- Returns:
this
-
relationalDatabaseParameters
@Stability(Stable) public CfnDatabaseMixinProps.Builder relationalDatabaseParameters(List<? extends Object> relationalDatabaseParameters) Sets the value ofCfnDatabaseMixinProps.getRelationalDatabaseParameters()- Parameters:
relationalDatabaseParameters- An array of parameters for the database.- Returns:
this
-
rotateMasterUserPassword
@Stability(Stable) public CfnDatabaseMixinProps.Builder rotateMasterUserPassword(Boolean rotateMasterUserPassword) Sets the value ofCfnDatabaseMixinProps.getRotateMasterUserPassword()- Parameters:
rotateMasterUserPassword- A Boolean value indicating whether to change the primary user password to a new, strong password generated by Lightsail .The
RotateMasterUserPasswordandMasterUserPasswordparameters cannot be used together in the same template.- Returns:
this
-
rotateMasterUserPassword
@Stability(Stable) public CfnDatabaseMixinProps.Builder rotateMasterUserPassword(IResolvable rotateMasterUserPassword) Sets the value ofCfnDatabaseMixinProps.getRotateMasterUserPassword()- Parameters:
rotateMasterUserPassword- A Boolean value indicating whether to change the primary user password to a new, strong password generated by Lightsail .The
RotateMasterUserPasswordandMasterUserPasswordparameters cannot be used together in the same template.- Returns:
this
-
tags
Sets the value ofCfnDatabaseMixinProps.getTags()- Parameters:
tags- An array of key-value pairs to apply to this resource. For more information, see Tag in the AWS CloudFormation User Guide .The
ValueofTagsis optional for Lightsail resources.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnDatabaseMixinProps>- Returns:
- a new instance of
CfnDatabaseMixinProps - Throws:
NullPointerException- if any required attribute was not provided
-