@@ -38,6 +38,7 @@ class CreateDBInstanceRequest(object):
3838 'db_engine_version' : 'str' ,
3939 'db_minor_version' : 'str' ,
4040 'db_time_zone' : 'str' ,
41+ 'deletion_protection' : 'str' ,
4142 'instance_name' : 'str' ,
4243 'lower_case_table_names' : 'str' ,
4344 'node_number' : 'int' ,
@@ -63,6 +64,7 @@ class CreateDBInstanceRequest(object):
6364 'db_engine_version' : 'DBEngineVersion' ,
6465 'db_minor_version' : 'DBMinorVersion' ,
6566 'db_time_zone' : 'DBTimeZone' ,
67+ 'deletion_protection' : 'DeletionProtection' ,
6668 'instance_name' : 'InstanceName' ,
6769 'lower_case_table_names' : 'LowerCaseTableNames' ,
6870 'node_number' : 'NodeNumber' ,
@@ -82,7 +84,7 @@ class CreateDBInstanceRequest(object):
8284 'zone_ids' : 'ZoneIds'
8385 }
8486
85- def __init__ (self , auto_renew = None , charge_type = None , db_engine_version = None , db_minor_version = None , db_time_zone = None , instance_name = None , lower_case_table_names = None , node_number = None , node_spec = None , number = None , period = None , period_unit = None , port = None , pre_paid_storage_in_gb = None , project_name = None , storage_charge_type = None , subnet_id = None , super_account_name = None , super_account_password = None , tags = None , vpc_id = None , zone_ids = None , _configuration = None ): # noqa: E501
87+ def __init__ (self , auto_renew = None , charge_type = None , db_engine_version = None , db_minor_version = None , db_time_zone = None , deletion_protection = None , instance_name = None , lower_case_table_names = None , node_number = None , node_spec = None , number = None , period = None , period_unit = None , port = None , pre_paid_storage_in_gb = None , project_name = None , storage_charge_type = None , subnet_id = None , super_account_name = None , super_account_password = None , tags = None , vpc_id = None , zone_ids = None , _configuration = None ): # noqa: E501
8688 """CreateDBInstanceRequest - a model defined in Swagger""" # noqa: E501
8789 if _configuration is None :
8890 _configuration = Configuration ()
@@ -93,6 +95,7 @@ def __init__(self, auto_renew=None, charge_type=None, db_engine_version=None, db
9395 self ._db_engine_version = None
9496 self ._db_minor_version = None
9597 self ._db_time_zone = None
98+ self ._deletion_protection = None
9699 self ._instance_name = None
97100 self ._lower_case_table_names = None
98101 self ._node_number = None
@@ -120,6 +123,8 @@ def __init__(self, auto_renew=None, charge_type=None, db_engine_version=None, db
120123 self .db_minor_version = db_minor_version
121124 if db_time_zone is not None :
122125 self .db_time_zone = db_time_zone
126+ if deletion_protection is not None :
127+ self .deletion_protection = deletion_protection
123128 if instance_name is not None :
124129 self .instance_name = instance_name
125130 if lower_case_table_names is not None :
@@ -280,6 +285,34 @@ def db_time_zone(self, db_time_zone):
280285
281286 self ._db_time_zone = db_time_zone
282287
288+ @property
289+ def deletion_protection (self ):
290+ """Gets the deletion_protection of this CreateDBInstanceRequest. # noqa: E501
291+
292+
293+ :return: The deletion_protection of this CreateDBInstanceRequest. # noqa: E501
294+ :rtype: str
295+ """
296+ return self ._deletion_protection
297+
298+ @deletion_protection .setter
299+ def deletion_protection (self , deletion_protection ):
300+ """Sets the deletion_protection of this CreateDBInstanceRequest.
301+
302+
303+ :param deletion_protection: The deletion_protection of this CreateDBInstanceRequest. # noqa: E501
304+ :type: str
305+ """
306+ allowed_values = ["disabled" , "enabled" ] # noqa: E501
307+ if (self ._configuration .client_side_validation and
308+ deletion_protection not in allowed_values ):
309+ raise ValueError (
310+ "Invalid value for `deletion_protection` ({0}), must be one of {1}" # noqa: E501
311+ .format (deletion_protection , allowed_values )
312+ )
313+
314+ self ._deletion_protection = deletion_protection
315+
283316 @property
284317 def instance_name (self ):
285318 """Gets the instance_name of this CreateDBInstanceRequest. # noqa: E501
0 commit comments