Azure Cosmos DB announced Continuous Backup in Cosmos DB on March 2021. This feature is currently in public preview mode and It is not recommended to use in production. This option gives you more options for your backup requirements. You might be using Azure Data Factory to handle your custom backup needs. Azure Data Factory is the SSIS in cloud. ETL jobs can be problematic. Backing up a database is half of the problem; other half is restoring a database. Until now, we had to call Microsoft to restore Cosmos DB databases/accounts.
To restore, select a restore point and what and where you want to restore the backup. It is pretty easy process. You need to figure out the UTC time yourself. This might cause problems if you select a wrong time.
By using Continuous backup, you can easily backup and restore your database. For now, this option is available only for SQL API and Mongo API. There are many limitations in this public preview version. I am sure many of these limitations will go away when it becomes generally available to everybody.
You can get the full list of current limitations from this link. I shared some of the big ones here.
- Continuous Backup is available only for new accounts. You cannot convert your current backup policy.
- Multi-regions write accounts and Synapse Link enable accounts are not supported.
- The restore window is only 30 days and you cannot change it.
- Azure sovereign and Azure Government regions do not support it.
Continuous backup does not cost you any Request Units. If your database is available in different regions, Cosmos DB will back up your data in each region's Azure Blob storage. Backups will not include the following items.
- Network settings (Firewall, VNET, private endpoint settings)
- Consistency levels. (Default will be Session for all restored databases)
- Regions
- Stored procedures, triggers, and User Defined Functions.
You need to be careful if you use TTL in your restored databases. As soon as your database become available, some of the data might get deleted because of TTL settings. Your restore timestamp must be before the TTL properties were added into the container.
To enable continuous backup, I need to create a new account. Backup Policy tab is available only in the new account page.
No comments:
Post a Comment