org.apache.catalina.ha

Interface ClusterDeployer

public interface ClusterDeployer extends ChannelListener

A ClusterDeployer interface allows to plug in and out the different deployment implementations

Version: $Revision: 467222 $, $Date: 2006-10-24 05:17:11 +0200 (Tue, 24 Oct 2006) $

Author: Filip Hanik

Field Summary
Stringinfo
Descriptive information about this component implementation.
Method Summary
voidbackgroundProcess()
call from container Background Process
CatalinaClustergetCluster()
Returns the cluster the cluster deployer is associated with
voidinstall(String contextPath, URL war)
Install a new web application, whose web application archive is at the specified URL, into this container and all the other members of the cluster with the specified context path.
voidremove(String contextPath, boolean undeploy)
Remove an existing web application, attached to the specified context path.
voidsetCluster(CatalinaCluster cluster)
Associates the cluster deployer with a cluster
voidstart()
Start the cluster deployer, the owning container will invoke this
voidstop()
Stops the cluster deployer, the owning container will invoke this

Field Detail

info

public String info
Descriptive information about this component implementation.

Method Detail

backgroundProcess

public void backgroundProcess()
call from container Background Process

getCluster

public CatalinaCluster getCluster()
Returns the cluster the cluster deployer is associated with

Returns: CatalinaCluster

install

public void install(String contextPath, URL war)
Install a new web application, whose web application archive is at the specified URL, into this container and all the other members of the cluster with the specified context path. A context path of "" (the empty string) should be used for the root application for this container. Otherwise, the context path must start with a slash.

If this application is successfully installed locally, a ContainerEvent of type INSTALL_EVENT will be sent to all registered listeners, with the newly created Context as an argument.

Parameters: contextPath The context path to which this application should be installed (must be unique) war A URL of type "jar:" that points to a WAR file, or type "file:" that points to an unpacked directory structure containing the web application to be installed

Throws: IllegalArgumentException if the specified context path is malformed (it must be "" or start with a slash) IllegalStateException if the specified context path is already attached to an existing web application IOException if an input/output error was encountered during installation

remove

public void remove(String contextPath, boolean undeploy)
Remove an existing web application, attached to the specified context path. If this application is successfully removed, a ContainerEvent of type REMOVE_EVENT will be sent to all registered listeners, with the removed Context as an argument. Deletes the web application war file and/or directory if they exist in the Host's appBase.

Parameters: contextPath The context path of the application to be removed undeploy boolean flag to remove web application from server

Throws: IllegalArgumentException if the specified context path is malformed (it must be "" or start with a slash) IllegalArgumentException if the specified context path does not identify a currently installed web application IOException if an input/output error occurs during removal

setCluster

public void setCluster(CatalinaCluster cluster)
Associates the cluster deployer with a cluster

Parameters: cluster CatalinaCluster

start

public void start()
Start the cluster deployer, the owning container will invoke this

Throws: Exception - if failure to start cluster

stop

public void stop()
Stops the cluster deployer, the owning container will invoke this

Throws: LifecycleException

Copyright © 2000-2011 Apache Software Foundation. All Rights Reserved.