Examples of ContextConfig


Examples of org.apache.catalina.startup.ContextConfig

    public void deployWebApps(AppInfo appInfo, ClassLoader classLoader) throws Exception {
        for (WebAppInfo webApp : appInfo.webApps) {
            if (getContextInfo(webApp) == null) {
                StandardContext standardContext = new StandardContext();
                standardContext.addLifecycleListener(new ContextConfig());
                standardContext.setPath("/" + webApp.contextRoot);
                standardContext.setDocBase(webApp.codebase);
                standardContext.setParentClassLoader(classLoader);
                standardContext.setDelegate(true);
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

                }
                if (configClassName != null) {
                    Class clazz = Class.forName(configClassName);
                    config = (LifecycleListener) clazz.newInstance();
                } else {
                    config = new ContextConfig();
                }
            } catch (Exception e) {
                log.warn("Error creating ContextConfig for " + parentName, e);
                throw e;
            }
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

                host.setAutoDeploy(false);
                Registry.getRegistry(null, null)
                    .registerComponent(host, parentName, null);
                mserver.invoke(parentName, "init", new Object[] {}, new String[] {} );
            }
            ContextConfig config = new ContextConfig();
            this.addLifecycleListener(config);

            log.debug( "AddChild " + parentName + " " + this);
            try {
                mserver.invoke(parentName, "addChild", new Object[] { this },
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

        context.setPath(path);
       
        if (cl != null)
            context.setParentClassLoader(cl);
       
        ContextConfig config = new ContextConfig();
        config.setCustomAuthenticators(authenticators);
        ((Lifecycle) context).addLifecycleListener(config);

        context.setDelegate(true);
        return (context);
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

        if( log.isDebugEnabled() )
            log.debug("Creating EJBWebService context '" + contextPath + "'.");

        TomcatEJBWebServiceContext context = new TomcatEJBWebServiceContext(contextPath, webServiceContainer, securityRealmName, realmName, transportGuarantee, authMethod, classLoader);

        ContextConfig config = new ContextConfig();
        config.setCustomAuthenticators(authenticators);
        ((Lifecycle) context).addLifecycleListener(config);

        return (context);

    }
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

        cl.start();
        loader = new ContainerLoader(cl);

        // create the webapp Context
        ctx = new StandardContext();
        ctx.addLifecycleListener(new ContextConfig());
        ctx.setName("/testContext");
        ctx.setDocBase(app1.getAbsolutePath());
        ctx.setLoader(loader);
    }
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

        // caution: this sets the parent of the webapp loader to the test classloader so it can find TestServlet
        // anything that relies on the TCCL may not work correctly
        ClassLoader cl = TestServlet.class.getClassLoader();
        ctx.setParentClassLoader(cl);

        ctx.addLifecycleListener(new ContextConfig());
        ctx.setName("/testContext");
        ctx.setDocBase(app2.getAbsolutePath());

// Doesn't work, see TUSCANY-328       
//        host.addChild(ctx);
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

                host.setAutoDeploy(false);
                Registry.getRegistry(null, null)
                    .registerComponent(host, parentName, null);
                mserver.invoke(parentName, "init", new Object[] {}, new String[] {} );
            }
            ContextConfig config = new ContextConfig();
            this.addLifecycleListener(config);

            if(log.isDebugEnabled())
                 log.debug( "AddChild " + parentName + " " + this);
            try {
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

                }
                if (configClassName != null) {
                    Class clazz = Class.forName(configClassName);
                    config = (LifecycleListener) clazz.newInstance();
                } else {
                    config = new ContextConfig();
                }
            } catch (Exception e) {
                log.warn("Error creating ContextConfig for " + parentName, e);
                throw e;
            }
View Full Code Here

Examples of org.apache.catalina.startup.ContextConfig

        context.setXmlValidation(xmlValidation);
        context.setXmlNamespaceAware(xmlNamespaceAware);
        context.setTldValidation(tldValidation);
        context.setTldNamespaceAware(tldNamespaceAware);
       
        ContextConfig contextConfig = new ContextConfig();
        context.addLifecycleListener(contextConfig);

        // Add the new instance to its parent component
        ObjectName pname = new ObjectName(parent);
        ObjectName deployer = new ObjectName(pname.getDomain()+
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.