Fork me on GitHub

i'm searching for the best architecture to handling data persisted at sql db in REST fashion, but will be some columns in that db which will hold the result of computation which depend on some factors, so that optional columns will have variable data, so update operation will be much, so the design in my mind is: REST API: /add POST ;; adding data /query GET ;; do some computation and update optional columns then return the results, maybe attached to cache layer to make everything faster


maybe i can add kafka here, so query request will get the data from db and push to kafka and computation done by a separate components and publish the results


computation layer will update the columns in the db as well


did anybody face the same situation, and have a better approach for that ?


leave out any external dependencies if not absolutely required; distributed systems can lead to incredible pain down the road


@synthomat spark, kafka and so on, does that what you meant ?


yes, that’s what I was referring to; maybe you’re using it already for something else, then please feel free to ignore my advice 😄