we are trying to achieve object replication in azure storage account. Currently we are able to achieve replication between source to destination, but wouldn’t able to do destination to source. what we wanted to achieve is, each region will have its own specific storage account and ours is kind of blue/green deployment. so, we need two way replication. for e.g
our Env1 storage replicates to Env2 Storage account and then we bring Env3 storage which will start replicate from Env2 storage account, post that we will scrap Env1 storage account. I understand that this is currently not possible with Azure storage any alternate PaaS service which we can use?
I was thinking custom solution like, logic app/function app which might do the job. Is there any other way to achieve?
2
Answers
Currently, two way replication is not possible. you have one storage account which acts as a driver and it will be replicated to other storage accounts where the replication enabled.
It is not possible to have replication happens from storage account 1 to 2 and vice versa, currently. it always happens from storage account 1 to 2.
Two-way replication requires destination to be write-enabled. As per the docs, we have the following note:
“After you create the replication policy, write operations to the destination container aren’t permitted. Any attempts to write to the destination container fail with error code 409 (Conflict). To write to a destination container for which a replication rule is configured, you must either delete the rule that is configured for that container, or remove the replication policy. Read and delete operations to the destination container are permitted when the replication policy is active.”
https://learn.microsoft.com/en-us/azure/storage/blobs/object-replication-overview#replication-rules
If it helps, you should be able to set up replication from B -> A on a different set of containers than the ones in the initial rule.
That said, if the container that is used to receive the replica needs to be write enabled in active-active fashion, can you please submit a detailed technical feedback on the feature and associated opportunity? We are also collecting use-cases and requests on active-active replication.
https://feedback.azure.com/d365community