Skip to content
CCPEDIAby Unity Nodes
App Development

Trigger reacting only to a heartbeat

2 posts364 views2 likesLast activity Apr 2021

  1. Leonid_RozenbergOP 1

    I know that we can configure a trigger to receive a heartbeat. Would it be possible to have a trigger emit events only at a scheduled heartbeat? The use case would be allow batch processing.

    My intuition is that one would keep track of the state of what we’re reacting to via updateState and only emit rules when the last Message was a heartbeat?

  2. bernhard 1

    Yes, that’s exactly right. If all the state you need is what you can get via query, you don’t need to react to other messages at all. So your updateState is a case statement where only the heatbeat case does anything.