I will be getting multiple Servlet requests form clients to update some entries in a DB. currently I use hibernate with Postgre. What I do is I read the DB for current value and then add one to that value and save on each request. But if two people read the DB on same time and add it it will not count as I want. I got some suggestions to make it "synchronized". But there can be a considerable delay for some users if number of requests get bigger.
Is there an faster way to update a value by +1, without reading and writing it? If the best practice is to use synchronizing then how to make it faster (less waiting time)?