datomic

phronmophobic 2026-02-25T19:25:00.060669Z

Is there a datomic setup where I could dump weekly https://github.com/phronmophobic/dewey data into a public read-only datomic db that anyone could query? Ideally, it would be cheap to host. I was thinking something like https://blog.phronemophobic.com/dewey-sql.html, but using datalog+datomic with data hosted somewhere cheap like S3.

rjsheperd 2026-03-31T21:04:42.509359Z

@smith.adriane did you ever find a stable solution to this? Looking at this issue w.r.t. creating a Datomic storage backend in Parquet to enable partial reads of a Datomic store.

phronmophobic 2026-03-31T21:56:44.882589Z

@rjsheperd Not yet! Maybe some day.

rjsheperd 2026-03-31T23:06:45.486009Z

Gotcha.

jaret 2026-03-31T23:09:26.130709Z

This is a nice reminder that we never got connected. I'd love to chat any time next week happy to meet 1-2:30 PST (4-5:30 est). Still want to chat about the upcoming feature to make sure it meets some needs.

rjsheperd 2026-03-31T23:16:20.756579Z

@jaret is this something that could serve as a drop-in replacement for the SQLite/Postgres backend?

jaret 2026-02-27T13:51:36.897219Z

@smith.adriane Would love to have a call with you. I think we may be working on a feature that would fit your needs and it might be releasing in the near term. (sorry if that's lame to say, but can't talk about it directly until we're design and code complete). Let me know if you have some time because running this feature by you would help us in development.

🧠 1
šŸ‘€ 2
ā¤ļø 1
phronmophobic 2026-02-27T17:16:15.173569Z

@jaret, that would be great. My schedule is pretty flexible next week if you want to suggest a PST-friendly time.

phronmophobic 2026-02-25T19:26:20.617489Z

That would also support a cheap-to-host web interface like https://cloogle.phronemophobic.com/name-search.html?q=read-cond&tables=keywords#

Alex Miller (Clojure team) 2026-02-25T19:39:36.567379Z

https://application.garden/signup ?

āž• 1
phronmophobic 2026-02-25T19:41:12.012219Z

Does that host a datomic db?

phronmophobic 2026-02-25T19:43:38.611219Z

My question is more if I can create a datomic setup where all the data is public and anyone can start a repl and start running queries against the data.

phronmophobic 2026-02-25T19:44:56.560479Z

I don't mind doing the devops work.

Alex Miller (Clojure team) 2026-02-25T19:44:59.776579Z

yes, it can host a datomic db (behind the app), so not exactly what you're asking

Alex Miller (Clojure team) 2026-02-25T19:45:33.013999Z

but it's the closest thing I can think of

Harold 2026-02-25T19:48:10.220129Z

Maybe put the data in datomic, and then just make a backup on S3. Then anyone could load that and do whatever they like.

phronmophobic 2026-02-25T19:49:01.114379Z

Another reason for making it so users run queries on their on hardware is for security. Presumably, it's not safe to run untrusted queries.

Harold 2026-02-25T19:49:10.249269Z

Public S3 bucket hosting ~$0.03/GB/month + some transfer/api costs that this project can probably ignore

phronmophobic 2026-02-25T19:49:33.967109Z

I don't think that would support a web interface that would allow anyone to run queries.

Harold 2026-02-25T19:49:46.897579Z

having them do it on their own datomic is safest. they can be a peer (to their own restored backup)

phronmophobic 2026-02-25T19:54:07.018449Z

Yea, if there were a way to set things up so folks could just point their datomic client at my s3 bucket, I would be happy to try hosting that. Maybe I'll try the backup thing at some point, but offering a public web interface would be much more accessible. It makes it much easier to share queries with other people via a URL.

šŸ‘ 1
Harold 2026-02-25T19:57:07.074399Z

> if there were a way to set things up so folks could just point their datomic client at my s3 bucket That's how datomic s3 backups work (anyone with IAM permission to read can restore the backup)

phronmophobic 2026-02-25T19:59:44.381069Z

Maybe I'm understanding incorrectly, but I thought restoring a backup would require copying the whole db and reindexing. In principle, it seems like you could run a query against an index by downloading substantially less.

favila 2026-02-25T20:01:45.220509Z

restoring a backup is just copying the db, indexes and all; it takes time, but it's only data transfer time

favila 2026-02-25T20:02:43.797489Z

whereever you see "segments", that's what's in storage, and that's what's in the backup. Restoring a backup just copies segments

favila 2026-02-25T20:02:55.095849Z

the end result is a fully usable db, no additional computation

favila 2026-02-25T20:04:07.363409Z

> In principle, it seems like you could run a query against an index by downloading substantially less. Yes, this is correct, but not because of reindexing; it's because you only needed a subset of segments to answer your query

šŸ‘ 2
phronmophobic 2026-02-25T20:07:20.117019Z

I already have an option to download a sqlite db. It's about 1gb compressed. My guess is that a datomic backup would be a few times larger? Downloading a few gbs isn't so bad. I may try that approach in the future. I'm still trying to find a way to let folks run arbitrary queries against the data from a web interface and/or from the repl with minimal setup on their end.

favila 2026-02-25T20:13:42.064009Z

the sqlite db is a datomic db?

favila 2026-02-25T20:13:52.400909Z

i.e. it is a contents of datomic storage, ready to go?

phronmophobic 2026-02-25T20:14:08.684359Z

the sqlite db is just a sqlite db with the data.

phronmophobic 2026-02-25T20:14:35.662009Z

I don't currently offer a format that is ready to be directly ingested by datomic.

šŸ‘ 1
favila 2026-02-25T20:15:16.643799Z

I would expect most equivalent sqlite dbs to be smaller, but it's not a given; depends on schema, history, indexes, etc

phronmophobic 2026-02-25T20:18:15.241559Z

It's not actually a sqlite db, it's the output of sqlite's .dump command. Something like:

~ adrian$ zless '/Users/adrian/Downloads/dewey.sqlite3.sql.gz' | head
PRAGMA foreign_keys=OFF;
BEGIN TRANSACTION;
CREATE TABLE IF NOT EXISTS "basis"
("id" INT NOT NULL, "repo" VARCHAR(256) NOT NULL, "sha" VARCHAR(256) NOT NULL, "basis" VARCHAR(256) NOT NULL);
INSERT INTO basis VALUES(0,'tonsky/FiraCode','9caf6ebcfd34e3ada08534bb1e6b9b71391653fd','/deps.edn');
INSERT INTO basis VALUES(1,'tonsky/datascript','100ab864f55e056df5837e77d44dfd0f8a447983','/deps.edn');
INSERT INTO basis VALUES(2,'tonsky/datascript','100ab864f55e056df5837e77d44dfd0f8a447983','/project.clj');
INSERT INTO basis VALUES(3,'tonsky/uberdeps','82af51ef14e6d6f56b440950fd068231889e825a','/deps.edn');
INSERT INTO basis VALUES(4,'tonsky/uberdeps','82af51ef14e6d6f56b440950fd068231889e825a','/project.clj');
INSERT INTO basis VALUES(5,'tonsky/uberdeps','82af51ef14e6d6f56b440950fd068231889e825a','/test_projects/just/deps.edn');
I assume that sort of thing compresses well, but my estimates are just guesses.

phronmophobic 2026-02-25T20:19:26.106269Z

Once loaded (which does take a while), the sqlite db file is ~6.5 gb.

xlfe 2026-04-18T23:20:05.898169Z

Once the "read only" datomic lands, you could have a S3 storage proxy laughcry https://clojurians.slack.com/archives/C03RZMDSH/p1771204710082289

2026-02-26T11:59:44.151049Z

Regarding the hosting. If you want more flexibility (like a VPS) https://www.hetzner.com/cloud/ is cheap, $5 a month, should cover the traffic and reasonable use?

phronmophobic 2026-04-01T16:48:48.377139Z

@jaret I’m available at that time on thursday, April 9th

jaret 2026-04-01T16:51:50.852999Z

Dm me you email and I'll send you an invite

borkdude 2026-04-29T11:55:04.734739Z

datomic now supports read-only connections

jaret 2026-04-29T12:20:18.194459Z

https://docs.datomic.com/operation/read-only.html

šŸ‘€ 1
šŸŽ‰ 1
rjsheperd 2026-04-29T16:45:04.956879Z

Very exciting

xlfe 2026-04-30T06:04:11.358349Z

Oh that's fantastic! Was eagerly awaiting this šŸ™‚