I am trying to use the “Send event task” and “Receive event task” activities on Flowable 6.7.2 version using Event Registry and ActiveMQ as JMS broker.
I was able to createa simply workflow (see picture) where I want to test the JMS send and receive messages.
I have realized that if the “Receive event task” activity is not yet active at the moment the event generated by JMS message created by the “Send event task” activity, the event will be missed.
I am wondering if it exist a way to use the JMS broker functionalities like message redelivery or DLQ handling (ActiveMQ) to be able to send the message again when the “Receive event task” activity will be ready ?
The Flowable Event Registry works in such a way that there can be multiple processes / cases listening on an event that arrives from JMS. This means that when an event comes in and it is not consumed it will be ignored.
Recently we added EventRegistryNonMatchingEventConsumer which allows you to handle events that have not been consumed by any process / case. You could look into that and do something that might help you in this particular use case.
What we would suggest is not to use logic like in your example when the receive event depends on the send event. If you need something like that, then the receive event should be done after the send event (or using a “Send and Receive Event Task”). Otherwise, you would be in a situation that is difficult to handle.
Hy @filiphr
thank you for your reply.
Unfortunately the messages we are waiting in the workflow is generated by an external system and we cannot control it. This means that we may miss messages if for any reason the workflow is not in the excepted status.