kcr_oracle_db_anthosapis_com 3.20260118.94513

Kubernetes Custom Resource Bindings
Documentation
// WARNING: generated by kopium - manual changes will be overwritten
// kopium command: kopium --docs --derive=Default --derive=PartialEq --smart-derive-elision --filename crd-catalog/GoogleCloudPlatform/elcarro-oracle-operator/oracle.db.anthosapis.com/v1alpha1/pitrs.yaml
// kopium version: 0.22.5

#[allow(unused_imports)]
mod prelude {
    pub use kube::CustomResource;
    pub use serde::{Serialize, Deserialize};
    pub use std::collections::BTreeMap;
    pub use k8s_openapi::apimachinery::pkg::apis::meta::v1::Condition;
}
use self::prelude::*;

/// PITRSpec defines the desired state of PITR
#[derive(CustomResource, Serialize, Deserialize, Clone, Debug, Default, PartialEq)]
#[kube(group = "oracle.db.anthosapis.com", version = "v1alpha1", kind = "PITR", plural = "pitrs")]
#[kube(namespaced)]
#[kube(status = "PitrStatus")]
#[kube(schema = "disabled")]
#[kube(derive="Default")]
#[kube(derive="PartialEq")]
pub struct PitrSpec {
    /// Schedule is a cron-style expression of the schedule on which Backup will be created for PITR. For allowed syntax, see en.wikipedia.org/wiki/Cron and godoc.org/github.com/robfig/cron. Default to backup every 4 hours.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "backupSchedule")]
    pub backup_schedule: Option<String>,
    /// Images defines PITR service agent images. This is a required map that allows a customer to specify GCR images.
    pub images: BTreeMap<String, String>,
    /// InstanceRef references to the instance that the PITR applies to.
    #[serde(rename = "instanceRef")]
    pub instance_ref: PitrInstanceRef,
    /// StorageURI is the URI to store PITR backups and redo logs. Currently only gs:// (GCS) schemes are supported.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "storageURI")]
    pub storage_uri: Option<String>,
}

/// InstanceRef references to the instance that the PITR applies to.
#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq)]
pub struct PitrInstanceRef {
    /// `name` is the name of a database instance.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
}

/// PITRStatus defines the observed state of PITR
#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq)]
pub struct PitrStatus {
    /// AvailableRecoveryWindowSCN represents the actual PITR recoverable SCN ranges for an instance in the current timeline/incarnation.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "availableRecoveryWindowSCN")]
    pub available_recovery_window_scn: Option<Vec<PitrStatusAvailableRecoveryWindowScn>>,
    /// AvailableRecoveryWindowTime represents the actual PITR recoverable time ranges for an instance in the current timeline/incarnation.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "availableRecoveryWindowTime")]
    pub available_recovery_window_time: Option<Vec<PitrStatusAvailableRecoveryWindowTime>>,
    /// BackupTotal stores the total number of current existing backups managed by a PITR.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "backupTotal")]
    pub backup_total: Option<i64>,
    /// Conditions represents the latest available observations of the PITR's current state.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub conditions: Option<Vec<Condition>>,
    /// CurrentDatabaseIncarnation stores the current database incarnation number for the PITR enabled instance.
    #[serde(default, skip_serializing_if = "Option::is_none", rename = "currentDatabaseIncarnation")]
    pub current_database_incarnation: Option<String>,
}

#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq)]
pub struct PitrStatusAvailableRecoveryWindowScn {
    /// Begin SCN.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub begin: Option<String>,
    /// End SCN.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub end: Option<String>,
}

#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq)]
pub struct PitrStatusAvailableRecoveryWindowTime {
    /// Begin time.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub begin: Option<String>,
    /// End time.
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub end: Option<String>,
}