datomic

2026-06-26T14:19:24.129619Z

Is there any tip here for producing a canonical schema on datomic to make a DB "merkle-tree" based? Which would be good performance-ish way to transact / read data given some hash for datomic? A good library for composing with the schema? šŸ˜„

Joe Lane 2026-06-26T14:29:58.321089Z

What does it mean to make a DB "Merkle-tree" based? What is your objective? (I know what Merkle-trees are)

2026-06-26T14:35:15.966349Z

I mean using Datomic as the immutable semantic log, then adding a cryptographic commitment layer over canonicalized events/datoms. Normal queries still use Datomic; Merkle roots are for audit/inclusion proofs kinda I’m trying to figure out the right direction more or less for: • schema design for canonical append-only events • where to store event hashes, tx roots, partition roots, entity roots • how to make writes idempotent with hashes/unique attrs • how to query by hash efficiently • what Clojure/Datomic libraries or patterns fit canonical hashing / Merkle proofs • what performance pitfalls to avoid Does that framing make sense? Is there a known good way to think about this in Datomic?

2026-06-26T14:37:09.664349Z

more or less, I want to understand some directions on those questions :))

2026-06-26T15:17:27.635759Z

Like I know some answers for those questions but I would like contributions that's why I've asked here

Joe Lane 2026-06-26T15:19:53.754069Z

What are your performance requirements? Especially for writes

Joe Lane 2026-06-26T15:21:52.377979Z

To you need a hash across the entire database or any hashes but each scoped to an entity

Joe Lane 2026-06-26T15:23:59.429089Z

If you share why you're trying to build this we may discover additional alternatives

2026-06-26T16:06:27.110069Z

yeah, mostly I would think on write cost to not scale with size of transaction/event batch, not with total database size. thanks Joe

2026-06-26T16:16:47.968539Z

but yeah, hard problems hehe