Consider an entity that can have multiple rows for each user and it has a property that should be true for only one row for a given user. I am on the NoSQL database (AWS DynamoDB)
On my service layer – create method, what is the best way to reset the property for all other rows for that user? An async method to fetch and update but I need to guarantee that the results (resets) are done before returning createResult to clients. Any clean architecture patterns or suggestions for a moderate scalability environment – say a million calls per hour?
I figure out I could move that property to user object to set the id of the entity but cannot change the model now.