Class AbstractCopyingInstalledLocalDeployer
- java.lang.Object
-
- org.codehaus.cargo.util.log.LoggedObject
-
- org.codehaus.cargo.container.spi.deployer.AbstractDeployer
-
- org.codehaus.cargo.container.spi.deployer.AbstractLocalDeployer
-
- org.codehaus.cargo.container.spi.deployer.AbstractInstalledLocalDeployer
-
- org.codehaus.cargo.container.spi.deployer.AbstractCopyingInstalledLocalDeployer
-
- Direct Known Subclasses:
JBossInstalledLocalDeployer
,Jetty6xInstalledLocalDeployer
,Jo1xInstalledLocalDeployer
,Jonas4xInstalledLocalDeployer
,Jonas5xInstalledLocalDeployer
,JRun4xInstalledLocalDeployer
,LibertyInstalledLocalDeployer
,ResinInstalledLocalDeployer
,TomcatCopyingInstalledLocalDeployer
,WebLogic9x10x12x14xCopyingInstalledLocalDeployer
public abstract class AbstractCopyingInstalledLocalDeployer extends AbstractInstalledLocalDeployer
Local deployer that deploys deployables to adeployable
directory of the given installed container. Note that this deployer supports some expanded deployables by copying the expanded deployable to thedeployable
directory. In other words it does not support in-place expanded deployables (e.g. expanded WARs located in a different directory).
-
-
Constructor Summary
Constructors Constructor Description AbstractCopyingInstalledLocalDeployer(LocalContainer container)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected boolean
canBeDeployed(Deployable newDeployable)
Checks whether the given Deployable can actually be deployed and whether a deployable has a web context path that already exist in another previously deployed Deployable.void
deploy(Deployable deployable)
Deploy aDeployable
to the running container and make it available for requests.protected void
doDeploy(String deployableDir, Deployable deployable)
Do the actual deployment.abstract String
getDeployableDir(Deployable deployable)
Specifies the directoryDeployable
s should be copied to.protected String
getDeployableName(Deployable deployable)
Gets the deployable name for the givendeployable
.void
setShouldDeployExpanded(DeployableType type, boolean flag)
Decide whether some expanded deployables of the specified type should be deployed or not.protected boolean
shouldDeployExpanded(DeployableType type)
-
Methods inherited from class org.codehaus.cargo.container.spi.deployer.AbstractInstalledLocalDeployer
getType
-
Methods inherited from class org.codehaus.cargo.container.spi.deployer.AbstractLocalDeployer
getContainer, getFileHandler
-
Methods inherited from class org.codehaus.cargo.container.spi.deployer.AbstractDeployer
deploy, deploy, redeploy, redeploy, redeploy, start, start, stop, stop, undeploy, undeploy
-
Methods inherited from class org.codehaus.cargo.util.log.LoggedObject
getLogger, setLogger
-
-
-
-
Constructor Detail
-
AbstractCopyingInstalledLocalDeployer
public AbstractCopyingInstalledLocalDeployer(LocalContainer container)
-
-
Method Detail
-
setShouldDeployExpanded
public void setShouldDeployExpanded(DeployableType type, boolean flag)
Decide whether some expanded deployables of the specified type should be deployed or not. Some classes using this deployer may not want to deploy some expanded deployables, as they may want to deploy them in-situ by modifying the container's configuration file to point to the location of the expanded deployable. This saves some copying time and make it easier for development round-trips.- Parameters:
type
- the deployable typeflag
- whether expanded deployment of the specified deployment type should be allowed or not
-
shouldDeployExpanded
protected boolean shouldDeployExpanded(DeployableType type)
- Parameters:
type
- the deployable type- Returns:
- whether expanded deployment of the specified deployment type should be done
-
deploy
public void deploy(Deployable deployable)
Deploy aDeployable
to the running container and make it available for requests.- Specified by:
deploy
in interfaceDeployer
- Overrides:
deploy
in classAbstractDeployer
- Parameters:
deployable
- theDeployable
to deploy
-
canBeDeployed
protected boolean canBeDeployed(Deployable newDeployable)
Checks whether the given Deployable can actually be deployed and whether a deployable has a web context path that already exist in another previously deployed Deployable.- Parameters:
newDeployable
- deployable- Returns:
- true, if the deployable can be deployed
-
getDeployableDir
public abstract String getDeployableDir(Deployable deployable)
Specifies the directoryDeployable
s should be copied to.- Parameters:
deployable
- Deployable to deploy.- Returns:
- Deployable directory
-
doDeploy
protected void doDeploy(String deployableDir, Deployable deployable)
Do the actual deployment. This can be overriden.- Parameters:
deployableDir
- Directory in which to deploy.deployable
- Deployable to deploy.
-
getDeployableName
protected String getDeployableName(Deployable deployable)
Gets the deployable name for the givendeployable
.- Parameters:
deployable
- Deployable to get the name for.- Returns:
- Deployable name.
-
-