ProtectedDatabase¶
-
class
oci.recovery.models.
ProtectedDatabase
(**kwargs)¶ Bases:
object
A protected database is an Oracle Cloud Database whose backups are managed by Oracle Database Autonomous Recovery Service. Each protected database requires a recovery service subnet and a protection policy to use Recovery Service as the backup destination for centralized backup and recovery
Attributes
DATABASE_SIZE_AUTO
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_L
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_M
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_S
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_XL
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_XS
A constant which can be used with the database_size property of a ProtectedDatabase. DATABASE_SIZE_XXL
A constant which can be used with the database_size property of a ProtectedDatabase. HEALTH_ALERT
A constant which can be used with the health property of a ProtectedDatabase. HEALTH_PROTECTED
A constant which can be used with the health property of a ProtectedDatabase. HEALTH_WARNING
A constant which can be used with the health property of a ProtectedDatabase. LIFECYCLE_STATE_ACTIVE
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_CREATING
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_DELETED
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_DELETE_SCHEDULED
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_DELETING
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_FAILED
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. LIFECYCLE_STATE_UPDATING
A constant which can be used with the lifecycle_state property of a ProtectedDatabase. change_rate
Gets the change_rate of this ProtectedDatabase. compartment_id
[Required] Gets the compartment_id of this ProtectedDatabase. compression_ratio
Gets the compression_ratio of this ProtectedDatabase. database_id
Gets the database_id of this ProtectedDatabase. database_size
[Required] Gets the database_size of this ProtectedDatabase. database_size_in_gbs
Gets the database_size_in_gbs of this ProtectedDatabase. db_unique_name
[Required] Gets the db_unique_name of this ProtectedDatabase. defined_tags
Gets the defined_tags of this ProtectedDatabase. display_name
Gets the display_name of this ProtectedDatabase. freeform_tags
Gets the freeform_tags of this ProtectedDatabase. health
Gets the health of this ProtectedDatabase. health_details
Gets the health_details of this ProtectedDatabase. id
[Required] Gets the id of this ProtectedDatabase. is_read_only_resource
Gets the is_read_only_resource of this ProtectedDatabase. is_redo_logs_shipped
Gets the is_redo_logs_shipped of this ProtectedDatabase. lifecycle_details
Gets the lifecycle_details of this ProtectedDatabase. lifecycle_state
Gets the lifecycle_state of this ProtectedDatabase. metrics
Gets the metrics of this ProtectedDatabase. policy_locked_date_time
Gets the policy_locked_date_time of this ProtectedDatabase. protection_policy_id
[Required] Gets the protection_policy_id of this ProtectedDatabase. recovery_service_subnets
[Required] Gets the recovery_service_subnets of this ProtectedDatabase. subscription_id
Gets the subscription_id of this ProtectedDatabase. system_tags
Gets the system_tags of this ProtectedDatabase. time_created
Gets the time_created of this ProtectedDatabase. time_updated
Gets the time_updated of this ProtectedDatabase. vpc_user_name
[Required] Gets the vpc_user_name of this ProtectedDatabase. Methods
__init__
(**kwargs)Initializes a new ProtectedDatabase object with values from keyword arguments. -
DATABASE_SIZE_AUTO
= 'AUTO'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “AUTO”
-
DATABASE_SIZE_L
= 'L'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “L”
-
DATABASE_SIZE_M
= 'M'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “M”
-
DATABASE_SIZE_S
= 'S'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “S”
-
DATABASE_SIZE_XL
= 'XL'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “XL”
-
DATABASE_SIZE_XS
= 'XS'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “XS”
-
DATABASE_SIZE_XXL
= 'XXL'¶ A constant which can be used with the database_size property of a ProtectedDatabase. This constant has a value of “XXL”
-
HEALTH_ALERT
= 'ALERT'¶ A constant which can be used with the health property of a ProtectedDatabase. This constant has a value of “ALERT”
-
HEALTH_PROTECTED
= 'PROTECTED'¶ A constant which can be used with the health property of a ProtectedDatabase. This constant has a value of “PROTECTED”
-
HEALTH_WARNING
= 'WARNING'¶ A constant which can be used with the health property of a ProtectedDatabase. This constant has a value of “WARNING”
-
LIFECYCLE_STATE_ACTIVE
= 'ACTIVE'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “ACTIVE”
-
LIFECYCLE_STATE_CREATING
= 'CREATING'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “CREATING”
-
LIFECYCLE_STATE_DELETED
= 'DELETED'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “DELETED”
-
LIFECYCLE_STATE_DELETE_SCHEDULED
= 'DELETE_SCHEDULED'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “DELETE_SCHEDULED”
-
LIFECYCLE_STATE_DELETING
= 'DELETING'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “DELETING”
-
LIFECYCLE_STATE_FAILED
= 'FAILED'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “FAILED”
-
LIFECYCLE_STATE_UPDATING
= 'UPDATING'¶ A constant which can be used with the lifecycle_state property of a ProtectedDatabase. This constant has a value of “UPDATING”
-
__init__
(**kwargs)¶ Initializes a new ProtectedDatabase object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):
Parameters: - id (str) – The value to assign to the id property of this ProtectedDatabase.
- display_name (str) – The value to assign to the display_name property of this ProtectedDatabase.
- compartment_id (str) – The value to assign to the compartment_id property of this ProtectedDatabase.
- db_unique_name (str) – The value to assign to the db_unique_name property of this ProtectedDatabase.
- vpc_user_name (str) – The value to assign to the vpc_user_name property of this ProtectedDatabase.
- database_size (str) – The value to assign to the database_size property of this ProtectedDatabase. Allowed values for this property are: “XS”, “S”, “M”, “L”, “XL”, “XXL”, “AUTO”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
- protection_policy_id (str) – The value to assign to the protection_policy_id property of this ProtectedDatabase.
- policy_locked_date_time (str) – The value to assign to the policy_locked_date_time property of this ProtectedDatabase.
- recovery_service_subnets (list[oci.recovery.models.RecoveryServiceSubnetDetails]) – The value to assign to the recovery_service_subnets property of this ProtectedDatabase.
- database_id (str) – The value to assign to the database_id property of this ProtectedDatabase.
- database_size_in_gbs (int) – The value to assign to the database_size_in_gbs property of this ProtectedDatabase.
- change_rate (float) – The value to assign to the change_rate property of this ProtectedDatabase.
- compression_ratio (float) – The value to assign to the compression_ratio property of this ProtectedDatabase.
- is_redo_logs_shipped (bool) – The value to assign to the is_redo_logs_shipped property of this ProtectedDatabase.
- time_created (datetime) – The value to assign to the time_created property of this ProtectedDatabase.
- time_updated (datetime) – The value to assign to the time_updated property of this ProtectedDatabase.
- lifecycle_state (str) – The value to assign to the lifecycle_state property of this ProtectedDatabase. Allowed values for this property are: “CREATING”, “UPDATING”, “ACTIVE”, “DELETE_SCHEDULED”, “DELETING”, “DELETED”, “FAILED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
- health (str) – The value to assign to the health property of this ProtectedDatabase. Allowed values for this property are: “PROTECTED”, “WARNING”, “ALERT”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
- is_read_only_resource (bool) – The value to assign to the is_read_only_resource property of this ProtectedDatabase.
- lifecycle_details (str) – The value to assign to the lifecycle_details property of this ProtectedDatabase.
- health_details (str) – The value to assign to the health_details property of this ProtectedDatabase.
- metrics (oci.recovery.models.Metrics) – The value to assign to the metrics property of this ProtectedDatabase.
- subscription_id (str) – The value to assign to the subscription_id property of this ProtectedDatabase.
- freeform_tags (dict(str, str)) – The value to assign to the freeform_tags property of this ProtectedDatabase.
- defined_tags (dict(str, dict(str, object))) – The value to assign to the defined_tags property of this ProtectedDatabase.
- system_tags (dict(str, dict(str, object))) – The value to assign to the system_tags property of this ProtectedDatabase.
-
change_rate
¶ Gets the change_rate of this ProtectedDatabase. The percentage of data changes that exist in the database between successive incremental backups.
Returns: The change_rate of this ProtectedDatabase. Return type: float
-
compartment_id
¶ [Required] Gets the compartment_id of this ProtectedDatabase. The OCID of the compartment that contains the protected database.
Returns: The compartment_id of this ProtectedDatabase. Return type: str
-
compression_ratio
¶ Gets the compression_ratio of this ProtectedDatabase. The compression ratio of the protected database. The compression ratio represents the ratio of compressed block size to expanded block size.
Returns: The compression_ratio of this ProtectedDatabase. Return type: float
-
database_id
¶ Gets the database_id of this ProtectedDatabase. The OCID of the protected database.
Returns: The database_id of this ProtectedDatabase. Return type: str
-
database_size
¶ [Required] Gets the database_size of this ProtectedDatabase. The size of the protected database. XS - Less than 5GB, S - 5GB to 50GB, M - 50GB to 500GB, L - 500GB to 1TB, XL - 1TB to 5TB, XXL - Greater than 5TB.
Allowed values for this property are: “XS”, “S”, “M”, “L”, “XL”, “XXL”, “AUTO”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
Returns: The database_size of this ProtectedDatabase. Return type: str
-
database_size_in_gbs
¶ Gets the database_size_in_gbs of this ProtectedDatabase. The size of the database in GBs, in gigabytes.
Returns: The database_size_in_gbs of this ProtectedDatabase. Return type: int
-
db_unique_name
¶ [Required] Gets the db_unique_name of this ProtectedDatabase. The dbUniqueName for the protected database in Recovery Service. You cannot change the unique name.
Returns: The db_unique_name of this ProtectedDatabase. Return type: str
Gets the defined_tags of this ProtectedDatabase. Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {“foo-namespace”: {“bar-key”: “value”}}. For more information, see Resource Tags
Returns: The defined_tags of this ProtectedDatabase. Return type: dict(str, dict(str, object))
-
display_name
¶ Gets the display_name of this ProtectedDatabase. The protected database name. You can change the displayName. Avoid entering confidential information.
Returns: The display_name of this ProtectedDatabase. Return type: str
Gets the freeform_tags of this ProtectedDatabase. Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {“bar-key”: “value”}
Returns: The freeform_tags of this ProtectedDatabase. Return type: dict(str, str)
-
health
¶ Gets the health of this ProtectedDatabase. Indicates the protection status of the database.
- A ‘PROTECTED’ status indicates that Recovery Service can ensure database recovery to any point in time within the entire recovery window. The potential data loss exposure since the last backup is:
- Less than 10 seconds, if Real-time data protection is enabled
- Less than 70 minutes if Real-time data protection is disabled
- A ‘WARNING’ status indicates that Recovery Service can ensure database recovery within the current recovery window - 1 day. The potential data loss exposure since the last backup is:
- Greater than 10 seconds, if Real-time data protection is enabled
- Greater than 60 minutes, if if Real-time data protection is disabled
An ‘ALERT’ status indicates that Recovery Service cannot recover the database within the current recovery window.
Allowed values for this property are: “PROTECTED”, “WARNING”, “ALERT”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
Returns: The health of this ProtectedDatabase. Return type: str
-
health_details
¶ Gets the health_details of this ProtectedDatabase. A message describing the current health of the protected database.
Returns: The health_details of this ProtectedDatabase. Return type: str
-
id
¶ [Required] Gets the id of this ProtectedDatabase. The OCID of the protected database.
Returns: The id of this ProtectedDatabase. Return type: str
-
is_read_only_resource
¶ Gets the is_read_only_resource of this ProtectedDatabase. Indicates whether the protected database is created by Recovery Service or created manually. Set to <b>TRUE</b> for a service-defined protected database. When you enable the OCI-managed automatic backups option for a database and set Recovery Service as the backup destination, then Recovery Service creates the associated protected database resource. Set to <b>FALSE</b> for a user-defined protected database.
Returns: The is_read_only_resource of this ProtectedDatabase. Return type: bool
-
is_redo_logs_shipped
¶ Gets the is_redo_logs_shipped of this ProtectedDatabase. The value TRUE indicates that the protected database is configured to use Real-time data protection, and redo-data is sent from the protected database to Recovery Service. Real-time data protection substantially reduces the window of potential data loss that exists between successive archived redo log backups. For this to be effective, additional configuration is needed on client side.
Returns: The is_redo_logs_shipped of this ProtectedDatabase. Return type: bool
-
lifecycle_details
¶ Gets the lifecycle_details of this ProtectedDatabase. Detailed description about the current lifecycle state of the protected database. For example, it can be used to provide actionable information for a resource in a Failed state.
Returns: The lifecycle_details of this ProtectedDatabase. Return type: str
-
lifecycle_state
¶ Gets the lifecycle_state of this ProtectedDatabase. The current state of the Protected Database.
Allowed values for this property are: “CREATING”, “UPDATING”, “ACTIVE”, “DELETE_SCHEDULED”, “DELETING”, “DELETED”, “FAILED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
Returns: The lifecycle_state of this ProtectedDatabase. Return type: str
-
metrics
¶ Gets the metrics of this ProtectedDatabase.
Returns: The metrics of this ProtectedDatabase. Return type: oci.recovery.models.Metrics
-
policy_locked_date_time
¶ Gets the policy_locked_date_time of this ProtectedDatabase. An RFC3339 formatted datetime string that specifies the exact date and time for the retention lock to take effect and permanently lock the retention period defined in the policy.
The retention lock feature controls whether Recovery Service strictly preserves backups for the duration defined in a policy. Retention lock is useful to enforce recovery window compliance and to prevent unintentional modifications to protected database backups. Recovery Service enforces a 14-day delay before the retention lock set for a policy can take effect.
Returns: The policy_locked_date_time of this ProtectedDatabase. Return type: str
-
protection_policy_id
¶ [Required] Gets the protection_policy_id of this ProtectedDatabase. The OCID of the protection policy associated with the protected database.
Returns: The protection_policy_id of this ProtectedDatabase. Return type: str
-
recovery_service_subnets
¶ [Required] Gets the recovery_service_subnets of this ProtectedDatabase. List of recovery service subnet resources associated with the protected database.
Returns: The recovery_service_subnets of this ProtectedDatabase. Return type: list[oci.recovery.models.RecoveryServiceSubnetDetails]
-
subscription_id
¶ Gets the subscription_id of this ProtectedDatabase. The OCID of the cloud service subscription to which the protected database is linked.
Returns: The subscription_id of this ProtectedDatabase. Return type: str
Gets the system_tags of this ProtectedDatabase. Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {“orcl-cloud”: {“free-tier-retained”: “true”}}. For more information, see Resource Tags
Returns: The system_tags of this ProtectedDatabase. Return type: dict(str, dict(str, object))
-
time_created
¶ Gets the time_created of this ProtectedDatabase. An RFC3339 formatted datetime string that indicates the created time for a protected database. For example: ‘2020-05-22T21:10:29.600Z’
Returns: The time_created of this ProtectedDatabase. Return type: datetime
-
time_updated
¶ Gets the time_updated of this ProtectedDatabase. An RFC3339 formatted datetime string that indicates the last updated time for a protected database. For example: ‘2020-05-22T21:10:29.600Z’
Returns: The time_updated of this ProtectedDatabase. Return type: datetime
-
vpc_user_name
¶ [Required] Gets the vpc_user_name of this ProtectedDatabase. The virtual private catalog (VPC) user credentials that authenticates the protected database to access Recovery Service.
Returns: The vpc_user_name of this ProtectedDatabase. Return type: str
-