Is there any chance of getting a garbled value for a key in memcached in multi thread environment?. If so how to avoid it with minimal time of synchronization?.
Using Java client to access memcached server
No. Memcache will return a value that somebody wrote previously, and not a garbled value. If you get/modify/put you have no guarantee that the put applies to the same value as the get. Use the cas (compare and set) operation if you need to synchronize.
来源:https://stackoverflow.com/questions/6611799/is-memcached-get-and-put-methods-are-thread-safe