Interface EventProcessorModule.CustomizationPhase<P extends EventProcessorModule,C extends EventProcessorConfiguration>

Type Parameters:
P - The specific type of EventProcessorModule being configured.
C - The specific type of EventProcessorConfiguration for the processor.
All Known Implementing Classes:
PooledStreamingEventProcessorModule, SubscribingEventProcessorModule
Enclosing interface:
EventProcessorModule

public static interface EventProcessorModule.CustomizationPhase<P extends EventProcessorModule,C extends EventProcessorConfiguration>
Configuration phase interface that provides methods for setting up event processor configurations.

This interface offers two approaches for finishing event processors setup:

  • notCustomized() - Just accepts the shared and type-specific configuration without customizing it
  • customized(BiFunction) - Incremental customization on top of shared and type-specific defaults
Since:
5.0.0
Author:
Mateusz Nowak
  • Method Summary

    Modifier and Type
    Method
    Description
    customized(BiFunction<Configuration,C,C> instanceCustomization)
    Customizes the processor configuration by applying modifications to the default configuration.
    default P
    Builds the processor module with the current configuration.
  • Method Details

    • customized

      P customized(BiFunction<Configuration,C,C> instanceCustomization)
      Customizes the processor configuration by applying modifications to the default configuration.

      This method applies processor-specific customizations on top of shared defaults from parent modules, providing the recommended approach for most configuration scenarios.

      Customizations compound: calling this method again applies the given instanceCustomization on top of the configuration the previous one returned, in registration order. Two customizations that set the same property therefore resolve to the value of the last one registered, while everything else each of them set is retained. This lets an integration configure a processor from its own settings without discarding what the application configured, or the other way around.

      Parameters:
      instanceCustomization - A function that receives the configuration and default processor config, returning the customized processor configuration.
      Returns:
      The configured processor module.
    • notCustomized

      default P notCustomized()
      Builds the processor module with the current configuration.
      Returns:
      The configured processor module.