Class EmbeddedContextConfig
- java.lang.Object
-
- org.apache.catalina.startup.ContextConfig
-
- org.jboss.arquillian.container.tomcat.embedded.EmbeddedContextConfig
-
- All Implemented Interfaces:
org.apache.catalina.LifecycleListener
public class EmbeddedContextConfig extends org.apache.catalina.startup.ContextConfigA customContextConfigfor use in the Embedded Tomcat container integration for Arquillian.This configuration disables processing of a default web.xml (typically "$CATALINA_BASE/conf/web.xml"), as we don't have one. Instead we leverage
Tomcat.initWebappDefaults(org.apache.catalina.Context)to apply the equivalent configuration prior to context start.This implementation also marks an unpacked WAR for deletion when the context is stopped.
- Author:
- Dan Allen, Ian Brandt
-
-
Field Summary
-
Fields inherited from class org.apache.catalina.startup.ContextConfig
authenticators, context, customAuthenticators, defaultWebXml, deploymentCount, DUMMY_LOGIN_CONFIG, handlesTypesAnnotations, handlesTypesNonAnnotations, hostWebXmlCache, initializerClassMap, ok, originalDocBase, sm, typeInitializerMap
-
-
Constructor Summary
Constructors Constructor Description EmbeddedContextConfig()Initialize the context config so to disable processing of the default global web.xml.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidbeforeStart()Override to apply the equivalent of the stock "$CATALINA_BASE/conf/web.xml" to contexts programmatically.protected voidfixDocBase()Override to assign an internal field that will trigger the removal of the unpacked WAR when the context is closed.-
Methods inherited from class org.apache.catalina.startup.ContextConfig
antiLocking, applicationAnnotationsConfig, authenticatorConfig, checkHandlesTypes, configureStart, configureStop, contextConfig, createContextDigester, createWebXml, destroy, generateClassFooter, generateClassHeader, getConfigBasePath, getContextWebXmlSource, getContextXmlJavaSource, getContextXmlPackageName, getDefaultWebXml, getGenerateCode, getGeneratedCodeLocation, getGeneratedCodePackage, getGlobalWebXmlSource, getHostConfigBase, getHostWebXmlSource, getUseGeneratedCode, getWebXmlSource, init, lifecycleEvent, processAnnotations, processAnnotationsFile, processAnnotationsInParallel, processAnnotationsJar, processAnnotationsStream, processAnnotationsStringArray, processAnnotationsUrl, processAnnotationsWebResource, processAnnotationWebFilter, processAnnotationWebInitParams, processAnnotationWebServlet, processClass, processClasses, processContextConfig, processJarsForWebFragments, processResourceJARs, processServletContainerInitializers, setCustomAuthenticators, setDefaultWebXml, validateSecurityRoles, webConfig
-
-
-
-
Method Detail
-
beforeStart
protected void beforeStart()
Override to apply the equivalent of the stock "$CATALINA_BASE/conf/web.xml" to contexts programmatically.- Overrides:
beforeStartin classorg.apache.catalina.startup.ContextConfig
-
fixDocBase
protected void fixDocBase() throws IOExceptionOverride to assign an internal field that will trigger the removal of the unpacked WAR when the context is closed.- Overrides:
fixDocBasein classorg.apache.catalina.startup.ContextConfig- Throws:
IOException
-
-