Fork me on GitHub

just playing around with crux, and wondered whether you’d considered supporting the lazy “mode” of querying by returning something that is reducible (like the plan function in next.jdbc) rather than having to manage a “snapshot” explicitly. I’m a clojure beginner so might be missing some advantage in having the snapshot explicit.


Hi @U053YSSSJ sorry for the delay in responding. A Crux snapshot makes efficient use of the underlying KV stores for when you want to run multiple Datalog queries against the same db. A db is really just a wrapper around a pair of transaction and valid times so it is very cheap to create and I think fully lazy. You can certainly run multiple queries without using snapshots at all, which might be useful when experimenting during development, but it will be less efficient.