org.eclipse.jetty.deploy
Class WebAppDeployer
java.lang.Object
org.eclipse.jetty.util.component.AbstractLifeCycle
org.eclipse.jetty.deploy.WebAppDeployer
- All Implemented Interfaces:
- LifeCycle
public class WebAppDeployer
- extends AbstractLifeCycle
Web Application Deployer.
The class searches a directory for and deploys standard web application.
At startup, the directory specified by setWebAppDir(String)
is searched
for subdirectories (excluding hidden and CVS) or files ending with ".zip"
or "*.war". For each webapp discovered is passed to a new instance
of WebAppContext
(or a subclass specified by getContexts()
.
ContextHandlerCollection.getContextClass()
This deployer does not do hot deployment or undeployment. Nor does
it support per webapplication configuration. For these features
see ContextDeployer
.
- See Also:
ContextDeployer}
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle |
addLifeCycleListener, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WebAppDeployer
public WebAppDeployer()
getConfigurationClasses
public String[] getConfigurationClasses()
setConfigurationClasses
public void setConfigurationClasses(String[] configurationClasses)
getContexts
public HandlerCollection getContexts()
setContexts
public void setContexts(HandlerCollection contexts)
getDefaultsDescriptor
public String getDefaultsDescriptor()
setDefaultsDescriptor
public void setDefaultsDescriptor(String defaultsDescriptor)
isExtract
public boolean isExtract()
setExtract
public void setExtract(boolean extract)
isParentLoaderPriority
public boolean isParentLoaderPriority()
setParentLoaderPriority
public void setParentLoaderPriority(boolean parentPriorityClassLoading)
getWebAppDir
public String getWebAppDir()
setWebAppDir
public void setWebAppDir(String dir)
getAllowDuplicates
public boolean getAllowDuplicates()
setAllowDuplicates
public void setAllowDuplicates(boolean allowDuplicates)
- Parameters:
allowDuplicates
- If false, do not deploy webapps that have already been deployed or duplicate context path
setAttribute
public void setAttribute(String name,
Object value)
- Set a contextAttribute that will be set for every Context deployed by this deployer.
- Parameters:
name
- value
-
getAttribute
public Object getAttribute(String name)
- Get a contextAttribute that will be set for every Context deployed by this deployer.
- Parameters:
name
-
- Returns:
removeAttribute
public void removeAttribute(String name)
- Remove a contextAttribute that will be set for every Context deployed by this deployer.
- Parameters:
name
-
doStart
public void doStart()
throws Exception
- Overrides:
doStart
in class AbstractLifeCycle
- Throws:
Exception
scan
public void scan()
throws Exception
- Scan for webapplications.
- Throws:
Exception
doStop
public void doStop()
throws Exception
- Overrides:
doStop
in class AbstractLifeCycle
- Throws:
Exception
Copyright © 1995-2009 Mort Bay Consulting. All Rights Reserved.