Continuous Backup & Point-in-Time Restore
← Back to DP-420 Terminology Reference
Category: Maintenance & Security
Summary: Continuous backups enabling self-service restore to any timestamp in the retention window.
Overview
Continuous backup mode continuously backs up Azure Cosmos DB data, enabling self-service point-in-time restore (PITR) to any timestamp within the retention period (7 or 30 days depending on tier), without needing to contact support. This is useful for recovering from accidental data deletion/corruption or application bugs with much finer granularity than periodic backup.
Azure Cosmos DB accounts with periodic mode backup policy can be migrated to continuous mode using the Azure portal, Azure CLI, Azure PowerShell, or Bicep templates. Migration from periodic to continuous mode is one-way and isn't reversible. After you migrate from periodic to continuous mode, you get the benefits of continuous mode.
// Set the backup policy for the Azure Cosmos DB account
AccountUpdateParameters accountUpdateParameters = new AccountUpdateParameters()
{
BackupPolicy = new ContinuousBackupPolicy()
{
Type = BackupPolicyType.Continuous,
}
};
await databaseAccount.ReplaceAccountAsync(accountUpdateParameters);
az cosmosdb update --resource-group "" --name "" \ --backup-policy-type "Continuous" --continuous-tier "Continuous7Days"
Feature / Configuration Periodic Backup (Default) Continuous Backup (Point-in-Time) Restore Mechanism Requires submitting an Azure support ticket. Self-service Point-in-Time Restore (PITR) via portal/CLI. Retention Window Configurable up to 1 month (720 hours). Fixed tiers: 7-day, 30-day, or 35-day. Backup Interval Configurable (minimum 1 hour). Continuous ongoing backup (no interval required). Storage Redundancy Replicated to a paired region via Geo-Redundant Storage (GRS). Stored locally in the account's existing regions (not automatically geo-resistant). Supported APIs All Azure Cosmos DB APIs. SQL, MongoDB, Gremlin, and Table (Cassandra is not supported). Cost Structure Default (2 copies) is free. Billed for additional copies/retention. 7-day storage is free. 30/35-day tiers incur storage costs. All restores incur a fee. Migration Can be migrated to Continuous mode. One-way only: Cannot revert back to Periodic.
Restored Data plane Databases Containers Items/documents Throughput ❌ Not restored Control plane Networking Security Regional settings Consistency settings Programmability objects (Sprocs, Triggers, UDFs) External integrations
More Info & Links
DP-420 Style Practice Questions
Q1. What capability does continuous backup mode enable that periodic backup does not?
- A. Self-service point-in-time restore to any timestamp within the retention window
- B. Multi-region writes
- C. Automatic index optimization
- D. Free throughput
Q2. Do you need to contact Microsoft support to perform a restore under continuous backup mode?
- A. No, restores can be self-service, initiated by the account owner
- B. Yes, a support ticket is always required
- C. Only for restores older than 24 hours
- D. Only when using the Cassandra API
Answer Key
Answers are listed at the very end so you can attempt the questions first.
- Q1 (Continuous Backup & Point-in-Time Restore): A. Self-service point-in-time restore to any timestamp within the retention window — Continuous backup enables self-service point-in-time restore to virtually any moment within the retention period.
- Q2 (Continuous Backup & Point-in-Time Restore): A. No, restores can be self-service, initiated by the account owner — Continuous backup allows account owners to self-service restore without needing to open a support request.
DP-420: Designing and Implementing Cloud-Native Applications Using Microsoft Azure Cosmos DB — term detail page