I was reading about counters. Then I wanted to know when to use INT vs COUNTER. I came across this link
Now, I understand when to use it and what it does. But my question here is "How counter works without read before write and locking" in distributed environment.