Class MessagingConfigurationDefaults

java.lang.Object
org.axonframework.messaging.core.configuration.MessagingConfigurationDefaults
All Implemented Interfaces:
ConfigurationEnhancer

public class MessagingConfigurationDefaults extends Object implements ConfigurationEnhancer
A ConfigurationEnhancer registering the default components of the MessagingConfigurer.

Will only register the following components if there is no component registered for the given class yet:

Furthermore, this enhancer will decorate the:

Since:
5.0.0
Author:
Steven van Beelen
  • Field Details

    • ENHANCER_ORDER

      public static final int ENHANCER_ORDER
      The order of this enhancer compared to others, equal to Integer.MAX_VALUE.
      See Also:
    • CONVERTING_COMMAND_GATEWAY_ORDER

      public static final int CONVERTING_COMMAND_GATEWAY_ORDER
      The order in which the ConvertingCommandGateway is applied to the CommandGateway in the ComponentRegistry. As such, any decorator with a lower value will be applied to the delegate, and any higher value will be applied to the ConvertingCommandGateway itself. Using the same value can either lead to application of the decorator to the delegate or the converting command gateway, depending on the order of registration.

      The order of the ConvertingCommandGateway is set to Integer.MIN_VALUE + 100 to ensure it is applied very early in the configuration process, but not the earliest to allow for other decorators to be applied.

      See Also:
  • Constructor Details

    • MessagingConfigurationDefaults

      public MessagingConfigurationDefaults()
  • Method Details

    • order

      public int order()
      Description copied from interface: ConfigurationEnhancer
      Returns the relative order this enhancer should be invoked in, compared to other instances.

      Use lower (negative) values for enhancers providing sensible defaults, and higher values for enhancers that should be able to override values potentially previously set. Defaults to 0 when not set.

      Specified by:
      order in interface ConfigurationEnhancer
      Returns:
      The order in which this enhancer should be invoked.
    • enhance

      public void enhance(@Nonnull ComponentRegistry registry)
      Description copied from interface: ConfigurationEnhancer
      Enhances the given registry with, for example, additional components and decorators.
      Specified by:
      enhance in interface ConfigurationEnhancer
      Parameters:
      registry - The registry instance to enhance.