Fork me on GitHub
#datomic
<
2016-05-10
>
sdegutis03:05:29

Does retracting an entity which has {:db/noHistory true} also result in excising that entity from the database?

sdegutis03:05:38

I read the part that says there are no guarantees about how much is removed (it could have more than it should seem to) but it also says the purpose of noHistory is to reduce storage usage, which seems to suggest that it would be a reasonable optimization.

bkamphaus03:05:52

@sdegutis: it’s not really equivalent to excision :db/noHistory is really just a performance hint that goes into effect with indexing. And :db/noHistory is on an attribute, not an entity. Entities are just projected from all facts about them, but an entity with only :db/noHistory attributes with all facts retracted could result in no facts for that entity in history.

sdegutis03:05:16

@bkamphaus: Right, and no facts about an entity throughout history is really not much different than having never existed in histoyr.

sdegutis15:05:07

The query docs (http://docs.datomic.com/query.html) don't mention that < and > can compare two :db.type/instant values. Is this undefined behavior that just happens to work? I'm pretty sure it's not allowed in plain Clojure, so it must be a Datomic-specific feature.

peterromfeld17:05:14

i quite like clojure, but i also wanna get back to elixir and phoenix for my BE.. but i also cant live without datomic anymore πŸ˜› is there a way to write a peer lib for other langs without using REST api? http is so slow...

peterromfeld17:05:13

or it all ends up to get java interop first, then use java peer lib

peterromfeld17:05:51

i cant look into the source to see how peer caching actually works 😞 im also not that senior to understand if it would make sense to have the lookup caching abstracted away with common things like redis or co, so it eventually could be easier to implement peer libs in other langs, just would be awesome if you could use datomic to full potential in every language!

peterromfeld17:05:37

silly me, i found how to look into source

peterromfeld17:05:30

its java (puke)

curtosis18:05:32

AFAIK, at present, a peer library has to be implemented by Cognitect. The wire protocol is not public, and reverse engineering would violate the license.

curtosis18:05:00

for one solution, you could look at https://github.com/psfblair/datomic_gen_server (not used, just aware of)

bvulpes18:05:13

@peterromfeld: there's always the REST API

bvulpes18:05:25

is there a shorthand to retract all values for an attribute?

spiralganglion19:05:03

@peterromfeld: I too have been spending a bit of time with Phoenix and wishing I could back it with Datomic. Doubtful it's high on anyone's list of priorities, but an Erlang peer lib would probably be a pretty huge deal if it ever happened.

bkamphaus20:05:28

We definitely are considering the requests to open up peer lib/full client capabilities to other languages, but no specific plans to share at this time.

bhagany21:05:51

if we're voting, +1 for erlang peer lib