Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Mea culpa on the docs, mea culpa. Better now [1].

In order for user code to impose invariants over the entire transaction, it must have access to the entire transaction. Entity predicates have such access (they are passed the after db, which includes the pending transaction and all other transactions to boot). Transaction functions are unsuitable, as they have access only to the before db. [2]

Use entity predicates for arbitrary functional validations of the entire transaction.

[1] https://docs.datomic.com/transactions/transactions.html#tran...

[2] https://docs.datomic.com/transactions/transaction-functions....



Somewhat unrelated ad docs: It appears that "Query" opens a deadlink


Thanks for the report! just fixed the link.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: