Interface ConfigurationSource


public interface ConfigurationSource
Additional source to load and update configuration.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    load(Configuration configuration)
    Load additional configuration.
    default void
    Explicitly reload the configuration source.
  • Method Details

    • load

      void load(Configuration configuration)
      Load additional configuration.

      At this load time the configuration has already loaded properties from files and resources and configuration can be read provide configuration to the source like URL's to load more configuration from etc.

      The Configuration.setProperty(String, String) method is used when loading the additional properties from the source.

      Also note that the source can additionally use Configuration.schedule(long, long, Runnable) to schedule a period task to for example refresh data etc.

      Parameters:
      configuration - The configuration with initially properties.
    • reload

      default void reload()
      Explicitly reload the configuration source.

      Generally the configuration source will schedule a periodic refresh of its configuration but there are cases like Lambda where it can be useful to trigger a refresh explicitly and manually (e.g. on Lambda invocation).