Datomic and AwDb are amazingly similar

13 views
Skip to first unread message

William la Forge

unread,
Jul 8, 2015, 1:40:15 PM7/8/15
to AgileWikiDevelopers
Here is a comparison between Datomic and AwDb. More details on the later, as I am more familiar with it.

Both Datomic and AwDB use the same 4-tuples consisting of
  • Entity - a unique id, the primary key of a row in a table.
  • Name - the name of a column in a table.
  • Value - The value or values assigned to a cell in a table.
  • Time - A unique timestamp or transaction identifier.
Both systems keep transaction logs, which is a time-ordered table. AwDt calls a log entry a journal entry and links it to all the entities that it changed. In the case of a journal entry then, E == T.

For every entry in the database, AwDb keeps a envt tuple. Datomic keeps both envt and nevt tuples.

AwDb has what it calls secondary keys. For these it keeps envt, nvet. Datomic also keeps nvet for selected names.

AwDb has what it calls labeled links for connecting entities, where the label is the n in the 4-tuple. For these it keeps envt, nvet, nevt and vnet.

Datomic also has a special case when the value is an entity id. In this case it also keeps a vant in addition to the envt and nevt. And may also keep the nvet.

One difference (and there are many) between AwDb and Datomic is in the size of v. AwDb works fine with a 128KB string for v, while Datomic works best with smaller strings. But then, for most attributes AwDB keeps only one tuple, envt. 

On the other hand, both systems support multiple v for otherwise identical tuples. Combine this with their similar use of time and tuple space and you get a very amazing coincidence.


Bill La Forge CTO

Reply all
Reply to author
Forward
0 new messages