public class AVMHost
extends org.apache.catalina.core.StandardHost
<Host name = "avm.localhost"
className = "org.alfresco.catalina.host.AVMHost"
appBase = "avm_webapps"
unpackWARs = "true"
autoDeploy = "true"
xmlValidation = "false"
xmlNamespaceAware = "false">
<!-- ... other args ... -->
</Host>
The addtional parameters it offers that aren't part of Catalina's
StandardHost implementation are:
className ="org.alfresco.catalina.host.AVMHost"
For example, suppose the default Catalina virtual host is
named "localhost", and it's accessed via DNS wildcarding using
some other name (e.g.: "alice.mysite.www--sandbox.avm.localhost").
What's needed is a way to say "every DNS wildcard name that
matches a regex pattern (reverseProxyBinding='...') should
act as a reverse proxy for a particular AVMHost-based virtual
host (e.g.: "avm.localhost"). If you don't provide
a reverseProxyBinding attribute explicitly, the following
pattern will be used:
"^(.+)\\.www--sandbox\\.(?:version--v(-?[\\d]+)\\.)?.*$"
--- --------
^ ^
| |
group 1 group 2
By default, the repository name will be taken from "group 1",
and the optional version will be taken from "group 2"
(see: DefaultAVMResourceBinding).
The resourceBindingClassName attribute allows you to customize
how a request to a reverse proxy maps to resources within the AVM repository.
While org.alfresco.catalina.host.DefaultAVMResourceBinding merely
takes "group 2" as a literal version number, you might want to do something
more sophisticated, such as map dates to AVM version numbers; this would
let you create "permalinks" that could be "guessed" by date. See the
AVMResourceBinding interface for more details.| Modifier and Type | Field and Description |
|---|---|
protected VirtServerRegistrationThread |
registrationThread_ |
backgroundProcessorDelay, children, cluster, controller, domain, lifecycle, listeners, loader, logger, logName, manager, mserver, name, oname, parent, parentClassLoader, pipeline, realm, resources, sm, started, suffix, support, type| Constructor and Description |
|---|
AVMHost() |
| Modifier and Type | Method and Description |
|---|---|
String |
getAppBase()
Return the (virtual) application root for this Host.
|
AVMHostConfig |
getAVMHostConfig() |
static AVMHostMatch |
getAVMHostMatch(String forwardProxyName) |
String |
getHostAppBase()
Returns the non-virtualized appBase value specified
for this host within $CATALINA_HOME/conf/server.xml.
|
String |
getInfo()
Return descriptive information about this Container implementation and
the corresponding version number, in the format
<description>/<version>. |
boolean |
getLazyDeploy() |
AVMResourceBinding |
getResourceBinding() |
String |
getResourceBindingClassName() |
String |
getReverseProxyBinding() |
static org.springframework.context.ApplicationContext |
GetSpringApplicationContext() |
void |
init() |
void |
setLazyDeploy(boolean lazyDeploy) |
void |
setLazyDeployExperimentalOnly(boolean lazyDeploy)
Deprecated.
|
void |
setResourceBindingClassName(String binding) |
void |
setReverseProxyBinding(String binding) |
void |
start()
Start this host.
|
void |
stop() |
String |
toString()
Return a String representation of this component.
|
addAlias, addChild, createObjectName, destroy, findAliases, getAliases, getAutoDeploy, getConfigClass, getContextClass, getDeployOnStartup, getErrorReportValveClass, getLiveDeploy, getName, getValveNames, getWorkDir, getXmlNamespaceAware, getXmlValidation, isDeployXML, isUnpackWARs, map, preRegister, removeAlias, setAppBase, setAutoDeploy, setConfigClass, setContextClass, setDeployOnStartup, setDeployXML, setErrorReportValveClass, setLiveDeploy, setName, setUnpackWARs, setWorkDir, setXmlNamespaceAware, setXmlValidationaddContainerListener, addLifecycleListener, addPropertyChangeListener, addValve, backgroundProcess, findChild, findChildren, findContainerListeners, findLifecycleListeners, fireContainerEvent, getBackgroundProcessorDelay, getBasic, getChildren, getCluster, getContainerSuffix, getDomain, getFirst, getJmxName, getJSR77Suffix, getLoader, getLogger, getManager, getMappingObject, getObjectName, getParent, getParentClassLoader, getParentName, getPipeline, getRealm, getResources, getType, getValveObjectNames, getValves, invoke, logName, postDeregister, postRegister, preDeregister, removeChild, removeContainerListener, removeLifecycleListener, removePropertyChangeListener, removeValve, setBackgroundProcessorDelay, setBasic, setCluster, setDomain, setLoader, setManager, setParent, setParentClassLoader, setRealm, setResources, threadStart, threadStopclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddContainerListener, addPropertyChangeListener, backgroundProcess, findChild, findChildren, findContainerListeners, getBackgroundProcessorDelay, getCluster, getLoader, getLogger, getManager, getMappingObject, getObjectName, getParent, getParentClassLoader, getPipeline, getRealm, getResources, invoke, removeChild, removeContainerListener, removePropertyChangeListener, setBackgroundProcessorDelay, setCluster, setLoader, setManager, setParent, setParentClassLoader, setRealm, setResourcesprotected VirtServerRegistrationThread registrationThread_
public String getReverseProxyBinding()
public void setReverseProxyBinding(String binding)
public void setLazyDeploy(boolean lazyDeploy)
@Deprecated public void setLazyDeployExperimentalOnly(boolean lazyDeploy)
public boolean getLazyDeploy()
public String getResourceBindingClassName()
public void setResourceBindingClassName(String binding)
public AVMResourceBinding getResourceBinding()
public AVMHostConfig getAVMHostConfig()
public static AVMHostMatch getAVMHostMatch(String forwardProxyName)
public String getInfo()
<description>/<version>.getInfo in interface org.apache.catalina.ContainergetInfo in class org.apache.catalina.core.StandardHostpublic String toString()
toString in class org.apache.catalina.core.StandardHostpublic String getAppBase()
getAppBase in interface org.apache.catalina.HostgetAppBase in class org.apache.catalina.core.StandardHostpublic String getHostAppBase()
public static org.springframework.context.ApplicationContext GetSpringApplicationContext()
public void init()
init in class org.apache.catalina.core.StandardHostpublic void start()
throws org.apache.catalina.LifecycleException
start in interface org.apache.catalina.Lifecyclestart in class org.apache.catalina.core.StandardHostorg.apache.catalina.LifecycleException - if this component detects a fatal error
that prevents it from being startedpublic void stop()
throws org.apache.catalina.LifecycleException
stop in interface org.apache.catalina.Lifecyclestop in class org.apache.catalina.core.ContainerBaseorg.apache.catalina.LifecycleExceptionCopyright © 2005–2014 Alfresco Software. All rights reserved.