ExternalConfigurationProviderPlugin - default implementation

In the base configuration, Guidewire provides a default implementation class for plugin ExternalConfigurationProviderPlugin:
  • FileBasedConfigurationProviderWrapper

The default class implements the ExternalConfigurationProviderPlugin interface.

Whatever the plugin implementation class, the plugin implementation class must contain the following public method:
  • lookupValue(String namespace, String key)
In this method:
  • namepace is a hard-coded string that uniquely identifies a given file group.
  • key is the identifier for the configuration placeholder .

The Substitutor process calls the lookupValue method every time it encounters a placeholder in a supported configuration file. The plugin method call then returns a substitution value for placeholder, which the Substitutor uses to replace the entire placeholder in the configuration file.

Placeholder examples

The following examples illustrate how to work with the lookupValue method:
  • The Substitutor replaces placeholder ${url} in file config.xml with the value returned by method lookupValue("config", "url").
  • The Substitutor replaces placeholder ${url} in file myPlugin.gwp with the value returned by method lookupValue("plugin", "url").

Lookup failure

If there is no default value and the plugin does not return a value:
  • PolicyCenter leaves the placeholder strings unchanged.
  • PolicyCenter places warning messages in the application log.

If a placeholder remains in a file used by the application server, it can cause the application server to fail, if not excluded from consideration due to an env or server configuration.