Fork me on GitHub
#xtdb
<
2021-03-22
>
Steven Deobald00:03:36

Thanks @kevin842... Jeremy or James will see this in a few hours, I'm guessing. 🙂

👍 3
Aleksander Rendtslev17:03:51

When do you register transaction functions? Right now I’m doing it every time I spin up a node. Meaning the same functions are registered again on each server restart. Is that understood correctly?

jarohen18:03:50

that's as good a time as any 🙂

🙌 3
Tuomas05:03:51

I was wondering about the same thing. If the functions have changed, you want to transact them, but if they haven't, you don't want to fill up the tx log for no reason. I thought that maybe I should do a custom tx function that fails if the fn body hasn't changed, but then realised how marginal the overhead probably is

Aleksander Rendtslev10:03:29

Exactly the same thoughts running through my head

jarohen11:03:04

if you re-submit the same document it won't take up any more space in the document store, and the addition to the tx-log will essentially be [[:crux.tx/put <20-byte-document-hash>]] - I suspect the custom tx-function will incur more overhead as invocations of the tx-fn do create a new document each time 🙂

Tuomas13:03:14

"invocations of the tx-fn do create a new document each time" Each tx function invocation is its own document?

jarohen13:03:58

yes - we separate out the arguments passed to the tx-fn as a separate document so that there's no chance of personally-identifiable information being in the transaction log

jarohen13:03:12

the tx-log can then be completely immutable, even in the presence of evicts

👍 3