Interface ConfigurationAmender


public interface ConfigurationAmender
Can be used to load properties which usually come from the configuration of @enterprise or of applications from other locations. This is agnostic to the mechanism or the origin of those configuration parameters, it could be files, environment variables, vaults and so on.

Is configured via property ep.configuration.amender.class.

The system will instantiate a single object of the class during startup.

Properties with type="Class" will never be read from a ConfigurationAmender.

  • Method Summary

    Modifier and Type
    Method
    Description
    getProperty(Configuration conf, String propertyName)
    Called to get the value of a property in the scope of a configuration
    default void
    Called when a configuration object is initially constructed by the system (at startup).
    boolean
    isAmendedProperty(Configuration conf, String propertyName)
    Called to determine if the configuration amender is responsible for a property in the scope of a configuration.
    default void
    Called when a configuration is reloaded by the system.
  • Method Details

    • init

      default void init(Configuration conf)
      Called when a configuration object is initially constructed by the system (at startup). It is first called with the @enterprise main configuration and then with the configurations of the applications in their specified startup order.
      Parameters:
      conf - the configuration which is constructed and to be amended
    • reload

      default void reload(Configuration conf)
      Called when a configuration is reloaded by the system. It is first called with the @enterprise main configuration and then with the configurations of the applications in their specified startup order.
      Parameters:
      conf - the configuration which is being reloaded
      Throws:
      Exception
    • isAmendedProperty

      boolean isAmendedProperty(Configuration conf, String propertyName)
      Called to determine if the configuration amender is responsible for a property in the scope of a configuration.
      Parameters:
      conf - the configuration ( of @enterprise or of an application)
      propertyName - the name of the property to check
      Returns:
    • getProperty

      Object getProperty(Configuration conf, String propertyName)
      Called to get the value of a property in the scope of a configuration
      Parameters:
      conf - the configuration ( of @enterprise or of an application)
      propertyName - the name of the property to get
      Returns:
      the value of the property according to the amender