Reactive or pubsub applications and Datomic


#1

Firstly: apologies if this is a neophyte question. I have looked through the Datmoic doco and done quite a bit of googling without an obvious answer.

I’m creating a series of services that are essentially Dataflow/Reactive/Stream-processing based (pick appropriate buzzword a la mode for a 60s concept).

It seems to me that rather than polling the tx report log every x seconds that it would be nice to register a callback to be triggered by a change to the tx report log, is this possible in a datomic peer?

Because I can’t find a simple answer to this it seems that I’m either a) missing a fundamental piece of info that makes this trivial or b) it’s just obviously not something that Datomic caters for, or even something that people are interested in.

Hoping for some useful info.

Fox

@sleepyfox


#2

Nevermind: just found http://blog.datomic.com/2013/10/the-transaction-report-queue.html


#3

It occurs to me that using the tx report queue only works if my app is a peer, which isn’t really a possibility for a lightweight service.

One possibility is to build a lightweight pubsub broker on top of a peer that monitors the tx report queue, but this seems to me to be in the category of ‘problems that someone has bound to have solved already’…

Any helpful ideas appreciated. I did find https://github.com/vlacs/flare but this appears to have been abandoned a loooong time ago.