ObjectStackObjectStack

Disaster Recovery

Disaster Recovery protocol schemas

Backup Strategy Schema

Defines backup methods for disaster recovery.

  • full: Complete snapshot of all data

  • incremental: Only changes since last backup

  • differential: All changes since last full backup

@example


const backup: BackupConfig = \{

strategy: 'incremental',

schedule: '0 2 * * *',

retention: \{ days: 30, minCopies: 3 \},

encryption: \{ enabled: true, algorithm: 'AES-256-GCM' \},

\};

Source: packages/spec/src/system/disaster-recovery.zod.ts

TypeScript Usage

import { BackupRetention, BackupStrategy, FailoverConfig, FailoverMode, RPO, RTO } from '@objectstack/spec/system';
import type { BackupRetention, BackupStrategy, FailoverConfig, FailoverMode, RPO, RTO } from '@objectstack/spec/system';

// Validate data
const result = BackupRetention.parse(data);

BackupRetention

Backup retention policy

Properties

PropertyTypeRequiredDescription
daysnumberRetention period in days
minCopiesnumberMinimum backup copies to retain
maxCopiesnumberoptionalMaximum backup copies to store

BackupStrategy

Backup strategy type

Allowed Values

  • full
  • incremental
  • differential

FailoverConfig

Failover configuration

Properties

PropertyTypeRequiredDescription
modeEnum<'active_passive' | 'active_active' | 'pilot_light' | 'warm_standby'>Failover mode
autoFailoverbooleanEnable automatic failover
healthCheckIntervalnumberHealth check interval in seconds
failureThresholdnumberConsecutive failures before failover
regionsObject[]Multi-region configuration (minimum 2 regions)
dnsObjectoptionalDNS failover settings

FailoverMode

Failover mode

Allowed Values

  • active_passive
  • active_active
  • pilot_light
  • warm_standby

RPO

Recovery Point Objective (maximum acceptable data loss)

Properties

PropertyTypeRequiredDescription
valuenumberRPO value
unitEnum<'seconds' | 'minutes' | 'hours'>RPO time unit

RTO

Recovery Time Objective (maximum acceptable downtime)

Properties

PropertyTypeRequiredDescription
valuenumberRTO value
unitEnum<'seconds' | 'minutes' | 'hours'>RTO time unit

On this page