Supporting master-master replication architecture