Class OverrideConnectorConfig

java.lang.Object
io.smallrye.reactive.messaging.providers.impl.ConnectorConfig
io.smallrye.reactive.messaging.providers.impl.OverrideConnectorConfig
All Implemented Interfaces:
org.eclipse.microprofile.config.Config

public class OverrideConnectorConfig extends ConnectorConfig
Represents a configuration class that allows overriding specific properties for a connector. If a nested-channel is defined, property lookups will be in the following order
  1. If nested-channel is given try [prefix].[channel].[nested-channel].[property-key]
  2. If an override function is given for a property-key, calls it converts the return value
  3. Calls the ConnectorConfig base function
The function getOriginalValue(String, Class) allows accessing the connector config without override.
See Also:
  • Constructor Details

  • Method Details

    • nestedChannelKey

      protected String nestedChannelKey(String keyName)
    • getOriginalValue

      public <T> Optional<T> getOriginalValue(String propertyName, Class<T> propertyType)
    • getValue

      public <T> T getValue(String propertyName, Class<T> propertyType)
      Specified by:
      getValue in interface org.eclipse.microprofile.config.Config
      Overrides:
      getValue in class ConnectorConfig
    • getOptionalValue

      public <T> Optional<T> getOptionalValue(String propertyName, Class<T> propertyType)
      Specified by:
      getOptionalValue in interface org.eclipse.microprofile.config.Config
      Overrides:
      getOptionalValue in class ConnectorConfig
    • getPropertyNames

      public Iterable<String> getPropertyNames()
      Gets the lists of config keys for the given connector. Note that the list contains property names from the config and env variables. It includes keys from the connector config and channel config.
      Specified by:
      getPropertyNames in interface org.eclipse.microprofile.config.Config
      Overrides:
      getPropertyNames in class ConnectorConfig
      Returns:
      the list of keys