Configuratorpublic interface Configurator Name of an implementation of this interface will be configured in the
META-INF/services/com.sun.appserv.addons.Configurator file. Appserver
will instantiate this class and use it for configuring and unconfiguring
the addon. |
Methods Summary |
---|
public void | configure(ConfigurationContext cc)Performs the configuration of the addon. Typically it involves
the creation of instance/domain specific artifacts and configuring
the domain.xml, server.policy etc.
When ConfigurationContext.ConfigurationType is DAS, the configurator
is supposed to make any changes required for the domain. For example,
it can insert a lifecycle-module element in the domain.xml with
object-type="system-all", so that the lifecycle module will be
available in all instances created in that domain.
The configurator is expected to use the system property called
com.sun.aas.AddonRoot for referring to the shared bits of the addon.
For example, the location of the system-all lifecycle module may be
specified as ${com.sun.aas.AddonRoot}//lib/lc-impl.jar
When ConfigurationContext.ConfigurationType is INSTANCE, the
configurator is expected to make any changes required for a particular
instance. This may be creating a system-propery to specify a
port number.
If this method throw a AddonFatalException or RuntimeException, the
appserver startup will not continue. If it throws AddonException,
then the appserver startup will continue after displaying the
error message.
| public void | disable(ConfigurationContext cc)Disable the addon. Typically, addon will modify some configuration
(eg: Lifecycle module) to stop it from functioning. If the addon
has deployed an application, then the application will be disabled
in this step.
If this method throw a AddonFatalException or RuntimeException, the
appserver startup will not continue. If it throws AddonException,
then the appserver startup will continue after displaying the
error message.
| public void | enable(ConfigurationContext cc)Enable the addon. Typically, addon will modify some configuration
(eg: Lifecycle module) to start functioning. If the addon has disabled
and application, then addon will re-enable that application in
this step.
If this method throw a AddonFatalException or RuntimeException, the
appserver startup will not continue. If it throws AddonException,
then the appserver startup will continue after displaying the
error message.
| public void | unconfigure(ConfigurationContext cc)Performs the unconfiguration of the addon. Typically it involves
the removal of instance/domain specific artifacts and deleting
the domain.xml entries. For example, all application-refs pointing
to the system application or may be removed by the addon.
If this method throw a AddonFatalException or RuntimeException, the
appserver startup will not continue. If it throws AddonException,
then the appserver startup will continue after displaying the
error message.
| public void | upgrade(ConfigurationContext cc, AddonVersion version)Upgrade the addon.
If this method throws AddonFatalException or RuntimeException, the
appserver startup will not continue. If it throws AddonException,
then the appserver startup will continue after displaying the
error message.
|
|