4 ms·
Y do you care what the DB knew at a specific time?
by throwaway7645 9y ago
Y do you care what the DB knew at a specific time?
- ertucetin 9y agoLet's say you are creating Git like system so you will need some data at specific time right?
- sbov 9y agoIt's useful in some scenarios, but I think the biggest benefit is debugging (something weird happened in prod? what was the database state?). I think people try to stretch its usefulness to scenarios where it doesn't quite fit. It almost fits for historical reports, but from my experience, usually you're going to find an error in your data that you want to fix "in the past" so those old reports change, and all of a sudden datomic doesn't automagically work for your historical reports anymore.
- throwaway7645 9y agoThat's interesting (debugging).
- fazzone 9y agoTo expand on the debugging bit, Datomic knows and can tell you the exact transaction responsible for every piece of data in the database. You can also see the complete state of the DB as of any transaction, but the complete history is more useful. It's like git blame for the database.
- ThrustVectoring 9y agoIt means that when you figure out how to calculate business metrics based off of information stored in Datomic, you get to compare how your business was doing versus how it's doing now for free. Or if you figure out a customer health score, it's now trivially easy to calculate how much it changed since last month.
- slowmovintarget 9y agoIt also means, if you're logging well, that you can replay the exact series of interactions, transactions included, that led to an end-user application failure. Untangled (ClojureScript on React) + Clojure / Datomic on the back-end.
- throwaway7645 9y agoNow that is neat!
- dragandj 9y agoAuditing, which might even be a legal requirement in some application domains.
- throwaway7645 9y agoI have audit tables in my relational database though...but its auditing is better?
- reilly3000 9y agoAll you have to do is call As-of in any expression to get a value relative to time, as the entire history of a named entity is stored efficiently with persistent data structures. It’s automatic, efficient, gives you the ability to query future values!
- always_good 9y agoI used it to show the edit history of forum posts until I found out the hard way that you're not to store long strings in Datomic.