I want to store a fairly complex JSON object in Redis but I can't see how I can make the transaction atomic, since I will have to get, edit, then set. In the time it's taken to edit, another get could have been called elsewhere which will eventually overwrite my data.
I have looked at Pipelines but it doesn't seem they will be useful, because the commands execute at the same time? Not possible to parse/edit before the set?
I also can't find a way to lock the document/hash during this proccess.
question from:https://stackoverflow.com/questions/66055250/atomic-redis-operations-with-json