Package org.flowable.eventregistry.api
Interface EventRegistry
- All Known Implementing Classes:
DefaultEventRegistry
public interface EventRegistry
Central registry for events that are received through external channels through a
InboundEventChannelAdapter
and then passed through as a event registry event.- Author:
- Joram Barrez
-
Method Summary
Modifier and TypeMethodDescriptionvoideventReceived(InboundChannelModel channelModel, String event) voideventReceived(InboundChannelModel channelModel, InboundEvent event) Events received in adapters should call this method to process events.generateKey(Map<String, Object> data) Method to generate the unique key used to correlate an event.voidregisterEventRegistryEventConsumer(EventRegistryEventConsumer eventRegistryEventBusConsumer) Registers aEventRegistryEventConsumerinstance (a consumer of event registry events which is created by any of the engines).voidremoveFlowableEventRegistryEventConsumer(EventRegistryEventConsumer eventRegistryEventBusConsumer) Removes the event consumer from the event registryvoidsendEventOutbound(EventInstance eventInstance, Collection<ChannelModel> channelModels) Send out theeventInstancevia the givenchannelModel(s).voidsendEventToConsumers(EventRegistryEvent eventRegistryEvent) Send an event to all the registered event consumers.voidsendSystemEventOutbound(EventInstance eventInstance) Send out theeventInstancevia the given systemOutboundEventProcessor.voidsetInboundEventProcessor(InboundEventProcessor inboundEventProcessor) TheInboundEventProcessoris responsible for handling any new event.voidsetOutboundEventProcessor(OutboundEventProcessor outboundEventProcessor) TheOutboundEventProcessoris responsible for handling sending out events.voidsetSystemOutboundEventProcessor(OutboundEventProcessor outboundEventProcessor) TheOutboundEventProcessoris responsible for handling sending system out events.
-
Method Details
-
setInboundEventProcessor
TheInboundEventProcessoris responsible for handling any new event. The event registry will simply pass any event it receives to this instance. -
setOutboundEventProcessor
TheOutboundEventProcessoris responsible for handling sending out events. The event registry will simply pass any event it needs to send to this instance. -
getSystemOutboundEventProcessor
OutboundEventProcessor getSystemOutboundEventProcessor() -
setSystemOutboundEventProcessor
TheOutboundEventProcessoris responsible for handling sending system out events. The event registry will simply pass any event it needs to send to this instance. -
registerEventRegistryEventConsumer
Registers aEventRegistryEventConsumerinstance (a consumer of event registry events which is created by any of the engines). -
removeFlowableEventRegistryEventConsumer
void removeFlowableEventRegistryEventConsumer(EventRegistryEventConsumer eventRegistryEventBusConsumer) Removes the event consumer from the event registry -
generateKey
Method to generate the unique key used to correlate an event.- Parameters:
data- data information used to generate the key (must not benull)- Returns:
- a unique string correlating the event based on the information supplied
-
eventReceived
-
eventReceived
Events received in adapters should call this method to process events. -
sendEventToConsumers
Send an event to all the registered event consumers. -
sendSystemEventOutbound
Send out theeventInstancevia the given systemOutboundEventProcessor. -
sendEventOutbound
Send out theeventInstancevia the givenchannelModel(s).
-