Interface EventProcessorModule
- All Superinterfaces:
Module
- All Known Implementing Classes:
PooledStreamingEventProcessorModule,SubscribingEventProcessorModule
Interface for configuring individual
EventProcessor modules.
This interface is typically not implemented or used directly. Instead, use the provided factory methods to create
specific processor modules, or access existing processors through parent module configurations like
SubscribingEventProcessorsConfigurer or PooledStreamingEventProcessorsConfigurer.
Example usage:
// Create a subscribing event processor
EventProcessorModule subscribingModule = EventProcessorModule
.subscribing("notification-processor")
.eventHandlingComponent(notificationHandler)
.customize((config, processorConfig) -> processorConfig
.messageSource(customMessageSource)
);
// Create a pooled streaming event processor
EventProcessorModule streamingModule = EventProcessorModule
.pooledStreaming("order-processor")
.eventHandlingComponent(orderHandler)
.notCustomized();
- Since:
- 5.0.0
- Author:
- Mateusz Nowak
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceEventProcessorModule.CustomizationPhase<P extends EventProcessorModule,C extends EventProcessorConfiguration> Configuration phase interface that provides methods for setting up event processor configurations.static interfaceEventProcessorModule.EventHandlingPhase<P extends EventProcessorModule,C extends EventProcessorConfiguration> Builder phase for configuring event handling components. -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic EventProcessorModule.EventHandlingPhase<PooledStreamingEventProcessorModule, PooledStreamingEventProcessorConfiguration> pooledStreaming(String processorName) Creates aPooledStreamingEventProcessorModulewith the given name.static EventProcessorModule.EventHandlingPhase<SubscribingEventProcessorModule, SubscribingEventProcessorConfiguration> subscribing(String processorName) Creates aSubscribingEventProcessorModulewith the given name.
-
Method Details
-
subscribing
static EventProcessorModule.EventHandlingPhase<SubscribingEventProcessorModule,SubscribingEventProcessorConfiguration> subscribing(@Nonnull String processorName) Creates aSubscribingEventProcessorModulewith the given name.- Parameters:
processorName- The processor name.- Returns:
- A builder phase to configure the subscribing event processor.
-
pooledStreaming
static EventProcessorModule.EventHandlingPhase<PooledStreamingEventProcessorModule,PooledStreamingEventProcessorConfiguration> pooledStreaming(@Nonnull String processorName) Creates aPooledStreamingEventProcessorModulewith the given name.- Parameters:
processorName- The processor name.- Returns:
- A builder phase to configure the pooled streaming event processor.
-