Ask questions on the official Q&A site at https://ask.datomic.com!
kschltz 2020-11-26T13:29:08.004900Z

We use datomic cloud + elastic search in a similar scenario described by pyry. It suits us just fine


The datomic REST-docs refer to the client-api for new projects. However how should non-jvm projects proceed? I'm ultimately trying to access datomic through ruby.



joshkh 2020-11-26T16:29:30.011100Z

using dev-local, is it possible to establish a client using a local binary from import-cloud and then divert all transactions to :mem? in other words, i want to unit test some functions using an established db but not persist d/transactions to it

steveb8n 2020-11-27T21:14:35.025500Z

@joshkh this lib does exactly what you want but not yet for cloud https://github.com/vvvvalvalval/datomock/issues/6

joshkh 2020-11-27T21:22:24.025800Z

thanks for sharing. i'm sticking to dev-local as being the "official" solution at the moment, and starting from a cloud db (whether remote or imported locally) is a must. no on-prem for me 🙂

joshkh 2020-11-26T16:35:17.011200Z

my answer isn't going to be particularly useful to you, but i've been picking apart this working nodejs + datomic cloud library in order to hopefully make a working cljs native version (and also explore a python client). https://github.com/csm/datomic-client-js

joshkh 2020-11-26T16:38:11.011500Z

so far it has been... tedious

joshkh 2020-11-26T16:46:36.011700Z

hey favila, both of your solutions worked. thanks. in my case i'm storing some rankings in tuples...

{:race/finishers [[0 sally-ref coach-1-ref]
                  [1 bob-ref nil]
                  [2 jane-ref coach-2-ref]]}
of course the alternative (and more verbose) solution is to have separate ranking entities that store all of the context (the race, the people involved, and a rank), but as an experiment i thought tuples might be an interesting solution. in my example i don't see why storing references in tuples seems like a bad idea.


That's amazing, i could translate your project to ruby as I only need a tiny subset. Reverse engineering the api seems like such a interesting approach


We use elastic search for the same purpose too. Even embedding the ES query inside datalog, so the queries are from the peer. This way the datomic client consumers do not need ES integration

joshkh 2020-11-26T21:11:46.013400Z

definitely! that project isn't mine though; i'm just reverse engineering it to port it to cljs and maybe python (like you might for ruby).

joshkh 2020-11-26T21:13:38.013600Z

it's a very useful blueprint and reveals some of the communication layers of Datomic Cloud. a big thumbs up to the author.


It feels like such a step backwards compared to the REST doc though. There was so much potential there (evident by the many languages who have support for it)

joshkh 2020-11-26T23:22:36.014100Z

i have to agree with you there. Datomic Cloud was a huge step to making Datomic accessible without the sysadmin overhead, and Ions did the same for deploying Clojure code without the devops. that being said, AWS promotes Lambda as a cloud-wide connective tissue (as does Ions i guess), and i have a laundry list of use cases for language support outside the JVM

joshkh 2020-11-26T23:27:28.014300Z

i asked the same question you did a few months ago and someone recommended rolling out my own Ion to proxy queries over an endpoint. it sounds like a fun project but there are probably things to consider, like how to secure it

joshkh 2020-11-26T23:31:48.014500Z

... meanwhile over in Neo4j land 😉 https://neo4j.com/docs/http-api/current/