Ask Your Question

race condition - upload newer version files VS fetching lastest files

asked 2011-07-11 15:15:14 -0500

shengjie-min gravatar image

I've been looking through the code and I didn't manage to find any evidence which prevents this:

It's 3 replicas cluster environment. If you have a file, let's say, version 1 uploaded in swift cluster already. Now you upload a newer version, version 2, to swift cluster with the same file name. It overwrites the older version on whatever zone you hit first. We know eventually, three replicas will be synched to version 2. BUT, Is it possible that, before the replication process completes, we would have two version 1 replicas in other two zones and one version 2 replica in the current zone.

And when user try to download the file from the cluster before the replication completion. Does that mean, he/she has chances to get the older version instead of the latest?

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted

answered 2011-07-12 12:49:09 -0500

shengjie-min gravatar image

thanks Ivan, it makes sense.

edit flag offensive delete link more

answered 2011-07-11 15:34:39 -0500

iizhikov gravatar image

Yes, and that's why it is called "eventually consistent object/blob store". You should forget about ACID when you are using Swift. It works just fine when you upload new picture or video to your web-site. But it should never be used in applications where ACID is the must, such as banking software.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2011-07-11 15:15:14 -0500

Seen: 40 times

Last updated: Jul 12 '11