备份 v1.3.0 自定义资源定义

选择文档版本:

规范架构

BackupSpec 定义备份的期望状态。

backupPlanRef: string
dbclusterRef: string
manual:
  physicalbackupSpec:
    backuptype: string
  type: boolean
physicalbackupSpec: string

字段

类型
必需或可选

 

说明
backupPlanRef
string
必需
创建此备份时所依据的 BackupPlan 的名称。
dbclusterRef
string
必需
此备份所属的 DBCluster 名称。
manual
boolean
可选
指示此备份是预定备份还是手动备份。如果未指定,则默认为 false(预定备份)。
manual.physicalbackupSpec
object
可选
包含物理备份的规范,允许将备份类型指定为 {"full","diff","incr"} 中的枚举。如果未指定,则默认为 full。
manual.physicalbackupSpec.backuptype
string
可选
要创建的备份的类型。它是 {"full","diff","incr"} 中的枚举。如果未指定,则默认为 full。

状态架构

BackupStatus 定义观察到的备份状态。

completeTime: string
conditions:
- lastTransitionTime: string
  message: string
  observedGeneration: integer
  reason: string
  status: string
  type: string
createTime: string
criticalIncidents:
- code: string
  createTime: string
  message: string
  messageTemplateParams: object
  resource:
    component: string
    location:
      cluster: string
      group: string
      kind: string
      name: string
      namespace: string
      version: string
  stackTrace:
  - component: string
    message: string
  transientUntil: string
observedGeneration: integer
phase: string
physicalbackupStatus:
  backupID: string
  priorBackup: string
reconciled: boolean
retainexpireTime: string

字段

类型
必需或可选

 

说明
completeTime
string
可选
备份的完成时间。
conditions[]
object
可选
表示实体当前状态的最新可用观察结果。
conditions[].lastTransitionTime
string
必需
条件上次从一种状态转换到另一种状态的时间。这应该是底层条件更改的时间。如果该信息未知,则可以使用 API 字段更改的时间。
conditions[].message
string
必需
人类可读的消息,指示有关转换的详细信息。这可能是空字符串。
conditions[].observedGeneration
integer
可选
表示设置条件所基于的 .metadata.generation。例如,如果 .metadata.generation 为 12,但 .status.conditions[x].observedGeneration 为 9,则表示条件相对于实例的当前状态已过时。
conditions[].reason
string
必需
包含一个程序化标识符,指示条件上次转换的原因。特定条件类型的生成者可以为此字段定义预期值和含义,以及这些值是否被视为有保证的 API。值应为 CamelCase 字符串。 此字段不得为空。
conditions[].status
string
必需
条件的状态,为 True、False、Unknown 之一。
conditions[].type
string
必需
条件的类型,采用 CamelCase 或 foo.example.com/CamelCase 形式。许多 .condition.type 值(例如 Available)在各个资源中是一致的,但由于任意条件都可能会有用(请参阅 .node.status.conditions),因此能够解决冲突非常重要。它匹配的正则表达式为 (dns1123SubdomainFmt/)?(qualifiedNameFmt)。
createTime
string
可选
备份的创建时间。
criticalIncidents[]
object
必需
CriticalIncidents 是所有活跃的严重突发事件的扁平列表。
criticalIncidents[].code
string
必需
此特定错误的错误代码。错误代码是 DBSE+数字字符串,例如“DBSE1012”。
criticalIncidents[].createTime
string
必需
在源头创建此突发事件时的时间戳。
criticalIncidents[].message
string
可选
Message 描述发生的突发事件/错误。
criticalIncidents[].messageTemplateParams
object
可选
包含在界面中生成人性化数据驱动型消息版本所需的键值对。
criticalIncidents[].resource
object
必需
包含有关报告突发事件的数据库服务组件的信息,以及有关 K8s 资源的信息。
criticalIncidents[].resource.component
string
必需
报告突发事件的数据库服务子系统的内部标识符。
criticalIncidents[].resource.location
object
可选
位置。
criticalIncidents[].resource.location.cluster
string
可选
受影响的 Kubernetes 资源的集群名称。
criticalIncidents[].resource.location.group
string
可选
Kubernetes 资源的组名称。
criticalIncidents[].resource.location.kind
string
可选
Kubernetes 资源的种类。
criticalIncidents[].resource.location.name
string
可选
受影响的 Kubernetes 资源的名称。
criticalIncidents[].resource.location.namespace
string
可选
受影响的 Kubernetes 资源的命名空间。
criticalIncidents[].resource.location.version
string
可选
Kubernetes 资源的版本。
criticalIncidents[].stackTrace
object
可选
来自堆栈轨迹的消息的非结构化列表。
criticalIncidents[].stackTrace.component
string
可选
记录消息的数据库服务组件的名称。
criticalIncidents[].stackTrace.message
string
可选
记录的消息。
criticalIncidents[].transientUntil
string
可选
如果存在,则指示在指定时间之前,问题应被视为暂时性问题。
observedGeneration
integer
可选
内部:控制器观察到的生成。
phase
string
可选
BackupPhase 是备份的阶段。
phase.physicalBackupStatus
object
可选
PhysicalBackupStatus 包含物理备份特有的状态信息。
phase.physicalBackupStatus.backupID
string
可选
pgbackrest 跟踪的物理备份的唯一 ID。
phase.physicalBackupStatus.priorBackup
string
可选
PriorBackup 是此备份所依赖的以前备份。
reconciled
boolean
可选
内部:资源是否由控制器进行了协调。
retainExpireTime
string
可选
RetainExpireTime 定义备份被删除的时间。这是一个仅输出字段,通过 create_time + retain_days 进行计算,会在备份的 retain_days 字段更新时进行相应更新。