Data sync problem in multisite
In zone A and zone B, if we upload a object obj to A. The data sync process is :
1. B get the bi log from A;
2. B fetch the obj from A according to the bi log, and then add a new bi log locally;
3. A get the bi log from B.
4. A fetch the obj from B according to the bi log, and B will return 304.
The process 4 isn't needed.
Besides, some strange problems may occur because of that process. For example, users upload obj and
In zone A, users have deleted obj, but the delete operation hasn't been synced;
Then according to process 4, A will fetch the obj from B. Because A's obj has been deleted, B will return the obj's data.
Then A will add a new bi log that obj is created and sync this bi log to B.
Now B will have one delete operation followed by one put operation. If these two operations are in the squash map, The put will override delete.
At last, the obj will not be deleted.