How does app42 service reacts if multiple users try to read/write same document. As an example, suppose that I have a document which has a key/value pair like "number_of_registered_users":"x", and every time a new user is being registered, he first reads "number_of_registered_users", then increments it and then writes back to document. What happens if
User1, reads "number_of_registered_users" as 1
User2, reads "number_of_registered_users" as 1
User1, increments 1 and writes back "number_of_registered_users" as 2
User2, increments 1 and writes back "number_of_registered_users" as 2, however he should have written it as 3.
p.s
The functionality that I'm trying to implement is when I'm registering a new user (not using the users api, but using storage api) through custom code, I want to return back the name of the user in the following format "user"+registed_users_count (ie user223).