Rule nodes such as "delay" and "deduplication" use the "tellSelf" method to schedule delay or to perform the deduplication analysis. tellSelf method sends messages to the current Rule Node with a specified millisecond delay. The main issue of this method is that message that sends using it is not queued and may be lost in case of a server restart.
tellSelf method:
/**
* Sends message to the current Rule Node with specified delay in milliseconds.
* Note: this message is not queued and may be lost in case of a server restart.
*
* @param msg
*/
void tellSelf(TbMsg msg, long delayMs);
Solution
Solution: Add the ability to use Redis cache with Sets implementation to store delayed messages and messages used in deduplication analysis.
Additional context
Rule node cache service will be stored in TbContext interface and can be accessed using the following method:
Issue
Rule nodes such as "delay" and "deduplication" use the "tellSelf" method to schedule delay or to perform the deduplication analysis. tellSelf method sends messages to the current Rule Node with a specified millisecond delay. The main issue of this method is that message that sends using it is not queued and may be lost in case of a server restart.
tellSelf method:
Solution
Solution: Add the ability to use Redis cache with Sets implementation to store delayed messages and messages used in deduplication analysis.
Additional context
Rule node cache service will be stored in TbContext interface and can be accessed using the following method:
Interface methods:
NOTE: List of methods might be changed in the final version. Check the updates in the corresponding release branch after the official release.