New answers tagged

1

I personally would not do this in a way that requires any back-and-forth messaging between the application and database. Leave the work to the RDBMS. You want to insert if the data does not exist else update if it is stale. I think the best option to achieve this is to essentially do an "UPSERT". You might look into how to do this on your particular RDBMS ...


1

I don't think you can easily solve this problem just by using clever SQL. One pattern that you may find useful here is the Actor Model, which you can combine with Consistent Hashing to build a system that effectively manages both parallelism and logical in-order processing of related messages. Basically, you can use the actor model to create agents that ...


1

It sounds like you are inventing Event Sourcing. I would avoid any processing on the SQL side, have my code load all the operations and process them in logical order into build the object state. This keeps your inserts fast and you can occasionally do snap shotting to limit the amount of data needed. However, you also have the problem of the time after ...


Top 50 recent answers are included