[英]Best way to copy an azure cosmos db to a dev cosmos db at regular intervals?
I'm looking to update my dev db to match my prod db at regular intervals (say weekly).我希望定期(比如每周)更新我的开发数据库以匹配我的生产数据库。 Is there a way to do this using Azure itself or do I need to write a script to do this?有没有办法使用 Azure 本身来执行此操作,还是我需要编写脚本来执行此操作?
Thank you!谢谢!
I have an idea upon your case but I'm not sure if it fits what you want.我对您的情况有一个想法,但我不确定它是否符合您的要求。 This is an answe r from @David Makogon to other question.这是@David Makogon 对其他问题的 r 的回答。 How do you think about exporting and importing documents manually?您如何看待手动导出和导入文档? Or trying to create an function to execute these operations which can be activated by time trigger.或者尝试创建一个 function 来执行这些可以通过时间触发器激活的操作。
I have tried migration tool, it's ok to import data.我试过迁移工具,导入数据就可以了。
I would suggest Azure Data Factory.我会建议 Azure 数据工厂。
Probably the easiest way these days would be to have the production account set up to use the continuous backup model .现在最简单的方法可能是将生产帐户设置为使用连续备份 model 。
This allows self service point in time restore to a new Cosmos account and can be set to either 30 day retention (chargeable) or 7 day (currently free).这允许自助服务时间点恢复到新的 Cosmos 帐户,并且可以设置为 30 天保留(收费)或 7 天(目前免费)。
There is a restore cost based on the GB size of data restored but this may well be cheaper than paying for the Request Units involved in reading batches from the source and writing them to the destination (unless the container is big and you are just writing incremental changes).有一个基于恢复数据的 GB 大小的恢复成本,但这可能比支付从源读取批次并将它们写入目标所涉及的请求单位要便宜(除非容器很大并且你只是写增量变化)。
The main caveats from this are主要注意事项是
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.