Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Managing the configuration parameter

To manage the configuration parameter, cloud-framework-config provides a Configurable interface.  By implementing this interface, the component declares itself to be a provider of configuration keys.  The keys and the default values are saved into the configuration table.

Code Block
public interface Configurable {

    /**
     * @return The name of the component that provided this configuration
     * variable.  This value is saved in the database so someone can easily
     * identify who provides this variable.
     **/
    String getConfigComponentName();

    /**
     * @return The list of config keys provided by this configuable.
     */
    ConfigKey<?>[] getConfigKeys();
}

...