Package org.apache.catalina

Examples of org.apache.catalina.Engine.addChild()


        // by default
        Engine engine = embedded.createEngine();
        engine.setDefaultHost("localhost");

        Host host = embedded.createHost("localhost", home + "/webapps");
        engine.addChild(host);

        Context root = embedded.createContext("", home + "/webapps/ROOT");
        host.addChild(root);

        Context examples = embedded.createContext("/examples",
View Full Code Here


                }

                // create engine
                Engine engine = container.createEngine();
                engine.setName( "localEngine-" + port );
                engine.addChild( host );
                engine.setDefaultHost( host.getName() );
                container.addEngine( engine );

                getLog().debug( "start tomcat instance on http port:" + port + " and protocol: " + protocol );
View Full Code Here

            engine.setRealm(realm);
        }
        //host
        for (HostType hostType: getHost()) {
            Host host = hostType.getHost(cl);
            engine.addChild(host);
        }
        //cluster
        if (getCluster() != null) {
            engine.setCluster(getCluster().getCluster(cl));
        }
View Full Code Here

        final Engine engine = tomcatServer.createEngine();
        engine.setDefaultHost("localhost");

        final Host host = tomcatServer.createHost("localhost", expandedPath);
        engine.addChild(host);

        final Context context = tomcatServer.createContext(contextPath, expandedPath);

        // Without a servlet the filter will not get run.
        final Wrapper wrapper = context.createWrapper();
View Full Code Here

        // Add the new instance to its parent component
        ObjectName pname = new ObjectName(parent);
        Service service = getService(pname);
        Engine engine = (Engine) service.getContainer();
        engine.addChild(host);

        // Return the corresponding MBean name
        return (host.getObjectName().toString());

    }
View Full Code Here

        // Add the new instance to its parent component
        ObjectName pname = new ObjectName(parent);
        Service service = getService(pname);
        Engine engine = (Engine) service.getContainer();
        engine.addChild(host);

        // Return the corresponding MBean name
        return (host.getObjectName().toString());

    }
View Full Code Here

    }

    /** {@inheritDoc} */
    public synchronized void addHost(Host host) {
        final Engine engine = this.engine;
        engine.addChild(host);
    }

    /** {@inheritDoc} */
    public synchronized void removeHost(Host host) {
        final Engine engine = this.engine;
View Full Code Here

        // Add the new instance to its parent component
        ObjectName pname = new ObjectName(parent);
        Service service = getService(pname);
        Engine engine = (Engine) service.getContainer();
        engine.addChild(host);

        // Return the corresponding MBean name
        return (host.getObjectName().toString());

    }
View Full Code Here

            engine.setRealm(realm);
        }
        //host
        for (HostType hostType: getHost()) {
            Host host = hostType.getHost(cl);
            engine.addChild(host);
        }
        //cluster
        if (getCluster() != null) {
            engine.setCluster(getCluster().getCluster(cl));
        }
View Full Code Here

        // Add the new instance to its parent component
        ObjectName pname = new ObjectName(parent);
        Service service = getService(pname);
        Engine engine = (Engine) service.getContainer();
        engine.addChild(host);

        // Return the corresponding MBean name
        return (host.getObjectName().toString());

    }
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.