|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.catalina.core.ContainerBase
org.apache.catalina.core.StandardHost
com.sun.enterprise.web.VirtualServer
public class VirtualServer
Standard implementation of a virtual server (aka virtual host) in the iPlanet Application Server.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.apache.catalina.core.ContainerBase |
|---|
ContainerBase.ContainerBackgroundProcessor, ContainerBase.PrivilegedAddChild |
| Field Summary | |
|---|---|
protected java.util.logging.Logger |
_logger
The logger to use for logging this virtual server |
protected static java.util.ResourceBundle |
rb
The resource bundle containing the message strings for _logger. |
| Fields inherited from class org.apache.catalina.core.StandardHost |
|---|
aliases |
| Fields inherited from class org.apache.catalina.core.ContainerBase |
|---|
backgroundProcessorDelay, checkIfRequestIsSecure, children, controller, debug, hasCustomPipeline, initialized, lifecycle, loader, logger, manager, mserver, name, notifyContainerListeners, oname, parent, parentClassLoader, pipeline, readLock, realm, resources, sm, started, suffix, support, type, writeLock |
| Fields inherited from interface org.apache.catalina.Deployer |
|---|
INSTALL_EVENT, PRE_INSTALL_EVENT, REMOVE_EVENT |
| Fields inherited from interface org.apache.catalina.Host |
|---|
ADD_ALIAS_EVENT, REMOVE_ALIAS_EVENT |
| Fields inherited from interface org.apache.catalina.Container |
|---|
ADD_CHILD_EVENT, ADD_MAPPER_EVENT, ADD_VALVE_EVENT, REMOVE_CHILD_EVENT, REMOVE_MAPPER_EVENT, REMOVE_VALVE_EVENT |
| Fields inherited from interface org.apache.catalina.Lifecycle |
|---|
AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, INIT_EVENT, START_EVENT, STOP_EVENT |
| Constructor Summary | |
|---|---|
VirtualServer()
Default constructor that simply gets a handle to the web container subsystem's logger. |
|
| Method Summary | |
|---|---|
void |
addContext(Context context,
java.lang.String contextRoot)
Registers the given Context with this VirtualServer at the given context root. |
protected void |
addListener(java.lang.String listenerName)
Adds the Catalina listener with the given class name to this VirtualServer. |
void |
addValve(GlassFishValve valve)
Adds the given valve to the currently active pipeline, keeping the pipeline that is not currently active in sync. |
protected void |
addValve(java.lang.String valveName)
Adds the Valve with the given class name to this
VirtualServer. |
void |
addValve(Valve valve)
Adds the given Tomcat-style valve to the currently active pipeline, keeping the pipeline that is not currently active in sync. |
void |
clearAliases()
Delete all aliases. |
void |
configure(java.lang.String vsID,
VirtualServer vsBean,
java.lang.String vsDocroot,
java.lang.String vsLogFile,
MimeMap vsMimeMap,
java.lang.String logServiceFile,
java.lang.String logLevel)
Configures this virtual server. |
protected void |
configureCatalinaProperties()
Configures the valve_ and listener_ properties of this VirtualServer. |
protected void |
configureRemoteAddressFilterValve(java.lang.String allow,
java.lang.String deny)
Configures the Remote Address Filter valve of this VirtualServer. |
void |
configureSingleSignOnCookieHttpOnly(javax.servlet.http.Cookie ssoCookie)
|
void |
configureSingleSignOnCookieSecure(javax.servlet.http.Cookie ssoCookie,
javax.servlet.http.HttpServletRequest hreq)
Configures the Secure attribute of the given SSO cookie. |
WebModuleConfig |
createSystemDefaultWebModuleIfNecessary(WebArchivist webArchivist)
If a default web module has not yet been configured and added to this virtual server's list of web modules then return the configuration information needed in order to create a default web module for this virtual server. |
Container |
findChild(java.lang.String contextRoot)
|
protected WebModuleConfig |
findWebModuleInJ2eeApp(Applications appsBean,
java.lang.String id,
ApplicationRegistry appRegistry)
Finds and returns information about a web module embedded within a J2EE application, which is identified by a string of the form a:b or a#b, where a is the name
of the J2EE application and b is the name of the embedded
web module. |
boolean |
getAllowLinking()
Gets the value of the allowLinking property of this virtual server. |
VirtualServer |
getBean()
Gets the config bean associated with this VirtualServer. |
java.lang.String[] |
getCacheControls()
Gets the Cache-Control configuration of this VirtualServer. |
VirtualServerConfig |
getConfig()
Gets the current configuration of this VirtualServer. |
Context |
getContext(java.lang.String contextRoot)
Finds the Context registered at the given context root. |
java.util.Collection<Context> |
getContexts()
Gets the collection of Context instances registered with this VirtualServer. |
protected java.lang.String |
getDefaultContextPath(Domain domain,
ApplicationRegistry appRegistry)
Gets the context root of the web module that the user/configuration has designated as the default-web-module for this virtual server. |
protected WebModuleConfig |
getDefaultWebModule(Domain domain,
WebArchivist webArchivist,
ApplicationRegistry appRegistry)
|
protected java.lang.String |
getDefaultWebModuleID()
Returns the id of the default web module for this virtual server as specified in the 'default-web-module' attribute of the 'virtual-server' element. |
java.io.File |
getDocRoot()
Gets the docroot of this VirtualServer. |
java.lang.String |
getID()
Return the virtual server identifier. |
java.lang.String |
getInfo()
|
MimeMap |
getMimeMap()
Gets the mime map associated with this VirtualServer. |
java.util.Collection<WebListener> |
getWebListeners()
Gets the collection of WebListener instances from which this VirtualServer receives requests. |
boolean |
isActive()
|
protected boolean |
isActive(WebModule wm,
boolean matchVSID)
Determines whether the specified web module is "active" under this virtual server. |
protected java.lang.Object |
loadInstance(java.lang.String className)
|
void |
removeContext(Context context)
Stops the given context and removes it from this VirtualServer. |
void |
removeValve(GlassFishValve valve)
Removes the given valve from the currently active pipeline, keeping the valve that is not currently active in sync. |
void |
setAllowLinking(boolean allowLinking)
Sets the allowLinking property of this virtual server, which determines whether symblic links from this virtual server's docroot are followed. |
void |
setBean(VirtualServer vsBean)
Sets the config bean for this VirtualServer |
void |
setCacheControls(java.lang.String[] cacheControls)
Sets the Cache-Control configuration for this VirtualServer |
void |
setClassLoaderHierarchy(ClassLoaderHierarchy clh)
|
void |
setCommandRunner(CommandRunner runner)
|
void |
setConfig(VirtualServerConfig config)
Reconfigures this VirtualServer with the given configuration. |
void |
setDefaultContextPath(java.lang.String defaultContextPath)
|
void |
setDocRoot(java.io.File docRoot)
Sets the docroot of this VirtualServer. |
void |
setDomain(Domain domain)
|
void |
setFileLoggerHandlerFactory(FileLoggerHandlerFactory factory)
|
void |
setHabitat(org.jvnet.hk2.component.Habitat habitat)
|
void |
setID(java.lang.String id)
Set the virtual server identifier string. |
void |
setIsActive(boolean isActive)
Sets the state of this virtual server. |
void |
setMimeMap(MimeMap mimeMap)
Sets the mime map for this VirtualServer |
void |
setRealm(Realm realm)
|
void |
setServerEnvironment(ServerEnvironment instance)
|
void |
setWebListeners(WebListener... webListeners)
Sets the collection of WebListener instances from which this VirtualServer receives requests. |
void |
stop()
|
void |
updateWebXml(ContextFacade facade,
java.io.File file)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected static final java.util.ResourceBundle rb
protected volatile java.util.logging.Logger _logger
| Constructor Detail |
|---|
public VirtualServer()
| Method Detail |
|---|
public java.lang.String getID()
getID in interface VirtualServerpublic void setID(java.lang.String id)
setID in interface VirtualServerid - New identifier for this virtual serverpublic boolean isActive()
public void setIsActive(boolean isActive)
isActive - true if this virtual server is active, false otherwisepublic boolean getAllowLinking()
public void setAllowLinking(boolean allowLinking)
allowLinking - Value of allowLinking propertypublic VirtualServer getBean()
public void setBean(VirtualServer vsBean)
public MimeMap getMimeMap()
public void setMimeMap(MimeMap mimeMap)
public java.lang.String[] getCacheControls()
public void setCacheControls(java.lang.String[] cacheControls)
cacheControls - Cache-Control configuration settings for this
VirtualServerpublic void setCommandRunner(CommandRunner runner)
public java.lang.String getInfo()
getInfo in interface ContainergetInfo in class StandardHostpublic void setDefaultContextPath(java.lang.String defaultContextPath)
public void setFileLoggerHandlerFactory(FileLoggerHandlerFactory factory)
public void setServerEnvironment(ServerEnvironment instance)
public void setClassLoaderHierarchy(ClassLoaderHierarchy clh)
public void setDomain(Domain domain)
public void setHabitat(org.jvnet.hk2.component.Habitat habitat)
public Container findChild(java.lang.String contextRoot)
findChild in interface ContainerfindChild in class StandardHost
public void configureSingleSignOnCookieSecure(javax.servlet.http.Cookie ssoCookie,
javax.servlet.http.HttpServletRequest hreq)
configureSingleSignOnCookieSecure in class StandardHostssoCookie - the SSO cookie to be configuredhreq - the HttpServletRequest that has initiated the SSO sessionpublic void configureSingleSignOnCookieHttpOnly(javax.servlet.http.Cookie ssoCookie)
configureSingleSignOnCookieHttpOnly in class StandardHostpublic void addValve(GlassFishValve valve)
addValve in interface PipelineaddValve in class StandardHostpublic void addValve(Valve valve)
addValve in interface PipelineaddValve in class ContainerBasepublic void removeValve(GlassFishValve valve)
removeValve in interface PipelineremoveValve in class StandardHost
protected java.lang.String getDefaultContextPath(Domain domain,
ApplicationRegistry appRegistry)
protected WebModuleConfig getDefaultWebModule(Domain domain,
WebArchivist webArchivist,
ApplicationRegistry appRegistry)
public WebModuleConfig createSystemDefaultWebModuleIfNecessary(WebArchivist webArchivist)
protected boolean isActive(WebModule wm,
boolean matchVSID)
wm - The bean containing the web module configuration
information as specified in server.xmlmatchVSID - This is set to false when testing to see if a
web module that has been configured to be the
default-web-module for a VS is active or not. In this
case the only test is to check if the web module
is enabled or not. When set to true, the virtual
server list is examined to ensure that the web
module has been configured to run on this virtual
server.
true if all the criteria are satisfied and
false otherwise.protected java.lang.String getDefaultWebModuleID()
protected WebModuleConfig findWebModuleInJ2eeApp(Applications appsBean,
java.lang.String id,
ApplicationRegistry appRegistry)
a:b or a#b, where a is the name
of the J2EE application and b is the name of the embedded
web module.
id does not identify a web module embedded
within a J2EE application.public void clearAliases()
public void configure(java.lang.String vsID,
VirtualServer vsBean,
java.lang.String vsDocroot,
java.lang.String vsLogFile,
MimeMap vsMimeMap,
java.lang.String logServiceFile,
java.lang.String logLevel)
protected void configureCatalinaProperties()
protected void addValve(java.lang.String valveName)
Valve with the given class name to this
VirtualServer.
valveName - The valve's fully qualified class namprotected void addListener(java.lang.String listenerName)
listenerName - The fully qualified class name of the listener
protected java.lang.Object loadInstance(java.lang.String className)
throws java.lang.Exception
loadInstance in class StandardHostjava.lang.Exception
protected void configureRemoteAddressFilterValve(java.lang.String allow,
java.lang.String deny)
public void setRealm(Realm realm)
setRealm in interface ContainersetRealm in class ContainerBasepublic void setDocRoot(java.io.File docRoot)
setDocRoot in interface VirtualServerdocRoot - the docroot of this VirtualServer.public java.io.File getDocRoot()
getDocRoot in interface VirtualServerpublic void setWebListeners(WebListener... webListeners)
webListeners - the collection of WebListener instances from which
this VirtualServer receives requests.public java.util.Collection<WebListener> getWebListeners()
getWebListeners in interface VirtualServer
public void addContext(Context context,
java.lang.String contextRoot)
throws ConfigException,
GlassFishException
If this VirtualServer has already been started, the given context will be started as well.
addContext in interface VirtualServerConfigException
GlassFishException
public void removeContext(Context context)
throws GlassFishException
removeContext in interface VirtualServerGlassFishExceptionpublic Context getContext(java.lang.String contextRoot)
getContext in interface VirtualServerpublic java.util.Collection<Context> getContexts()
getContexts in interface VirtualServer
public void setConfig(VirtualServerConfig config)
throws ConfigException
In order for the given configuration to take effect, this VirtualServer may be stopped and restarted.
setConfig in interface VirtualServerConfigExceptionpublic VirtualServerConfig getConfig()
getConfig in interface VirtualServer
public void stop()
throws LifecycleException
stop in interface Lifecyclestop in class ContainerBaseLifecycleException
public void updateWebXml(ContextFacade facade,
java.io.File file)
throws java.lang.Exception
java.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||