Examples of StoreDescription


Examples of org.apache.catalina.storeconfig.StoreDescription

    public static StoreDescription registerDescriptor(
            StoreDescription parentdesc, StoreRegistry registry, String id,
            String tag, String aClassToken, String factoryClass,
            boolean fstandard, boolean fdefault) {
        // add Listener
        StoreDescription descChild = new StoreDescription();
        descChild.setId(id);
        descChild.setTag(tag);
        descChild.setTagClass(aClassToken);
        descChild.setStandard(fstandard);
        descChild.setDefault(fdefault);
        descChild.setStoreFactoryClass(factoryClass);
        Object factory = null;
        try {
            Class aFactoryClass = Class.forName(factoryClass);
            factory = aFactoryClass.newInstance();
        } catch (Exception e) {
            log.error(e);
        }
        if (factory != null) {
            ((IStoreFactory) factory).setRegistry(registry);
            descChild.setStoreFactory((IStoreFactory) factory);
        }
        if (parentdesc != null)
            parentdesc.setChilds(true);
        registry.registerDescription(descChild);
        return descChild;
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     * @throws Exception
     */
    public static StoreDescription registerNamingDescriptor(
            StoreDescription parent, StoreRegistry registry) throws Exception {

        StoreDescription nameingDesc = DescriptorHelper.registerDescriptor(
                parent, registry, NamingResources.class.getName(),
                "NamingResources", NamingResources.class.getName(),
                "org.apache.catalina.storeconfig.NamingResourcesSF", true,
                false);
        registerDescriptor(nameingDesc, registry, ContextEjb.class.getName(),
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     * @throws Exception
     */
    public static StoreDescription registerClusterDescriptor(
            StoreDescription parent, StoreRegistry registry) throws Exception {

        StoreDescription clusterDesc = DescriptorHelper.registerDescriptor(
                parent, registry, CatalinaCluster.class.getName(), "Cluster",
                CatalinaCluster.class.getName(),
                "org.apache.catalina.storeconfig.CatalinaClusterSF", false,
                false);
        registerDescriptor(clusterDesc, registry,
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Host");
        desc.setTagClass("org.apache.catalina.core.StandardHost");
        desc.setStandard(true);
        desc.setStoreFactoryClass("org.apache.catalina.core.StandardHostSF");
        desc.addTransientAttribute("domain");
        registry.registerDescription(desc);
        factory = new StandardHostSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);
        StoreDescription listenerdesc = registerDescriptor("Listener",
                LifecycleListener.class);

        String listenerskippables[] = {
                "org.apache.catalina.core.NamingContextListener",
                "org.apache.catalina.startup.HostConfig", };
        for (int i = 0; i < listenerskippables.length; i++)
            listenerdesc.addTransientChild(listenerskippables[i]);

        StoreDescription realmdesc = registerDescriptor("Realm",
                JAASRealm.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        StoreDescription contextdesc = registerDescriptor("Context",
                StandardContext.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", true, false);
        String exceptions[] = { "available", "configFile", "configured",
                "distributable", "domain", "engineName", "name", "publicId",
                "sessionTimeout", "startupTime", "tldScanTime" };
        for (int i = 0; i < exceptions.length; i++)
            contextdesc.addTransientAttribute(exceptions[i]);

        StoreDescription valvedesc = registerDescriptor("Valve", Valve.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);

        String skippables[] = { "org.apache.catalina.core.StandardHostValve",
                "org.apache.catalina.valves.CertificatesValve",
                "org.apache.catalina.valves.ErrorReportValve",
                "org.apache.catalina.cluster.tcp.ReplicationValve",
                "org.apache.catalina.valves.RequestListenerValve", };
        for (int i = 0; i < skippables.length; i++)
            valvedesc.addTransientChild(skippables[i]);

        DescriptorHelper.registerClusterDescriptor(desc, registry);
        standardHost = new StandardHost();
        standardHost.setName("localhost");

View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Engine");
        desc.setTagClass("org.apache.catalina.core.StandardEngine");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardEngineSF");
        desc.addTransientAttribute("domain");
        registry.registerDescription(desc);
        factory = new StandardEngineSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);
        StoreDescription listenerdesc = registerDescriptor("Listener",
                LifecycleListener.class);

        String listenerskippables[] = {
                "org.apache.catalina.core.NamingContextListener",
                "org.apache.catalina.startup.ContextConfig",
                "org.apache.catalina.startup.EngineConfig",
                "org.apache.catalina.startup.HostConfig", };
        for (int i = 0; i < listenerskippables.length; i++)
            listenerdesc.addTransientChild(listenerskippables[i]);

        StoreDescription realmdesc = registerDescriptor("Realm",
                JAASRealm.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", true, false);
        StoreDescription hostdesc = registerDescriptor("Host",
                StandardHost.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", true, false);
        hostdesc.addTransientAttribute("domain");
        StoreDescription valvedesc = registerDescriptor("Valve", Valve.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);

        String skippables[] = {
                "org.apache.catalina.authenticator.BasicAuthenticator",
                "org.apache.catalina.authenticator.DigestAuthenticator",
                "org.apache.catalina.authenticator.FormAuthenticator",
                "org.apache.catalina.authenticator.NonLoginAuthenticator",
                "org.apache.catalina.authenticator.SSLAuthenticator",
                "org.apache.catalina.core.StandardContextValve",
                "org.apache.catalina.core.StandardEngineValve",
                "org.apache.catalina.core.StandardHostValve",
                "org.apache.catalina.valves.CertificatesValve",
                "org.apache.catalina.valves.ErrorReportValve",
                "org.apache.catalina.valves.RequestListenerValve", };
        for (int i = 0; i < skippables.length; i++)
            valvedesc.addTransientChild(skippables[i]);

        standardEngine = new StandardEngine();
        standardEngine.setName("Catalina");

    }
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Server");
        desc.setTagClass("org.apache.catalina.core.StandardServer");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardServerSF");
        registry.registerDescription(desc);
        factory = new StandardServerSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);
        StoreDescription listdesc = registerDescriptor("Listener",
                LifecycleListener.class);
        listdesc
                .addTransientChild("org.apache.catalina.core.NamingContextListener");
        listdesc
                .addTransientChild("org.apache.catalina.mbeans.ServerLifecycleListener");
        standardServer
                .addLifecycleListener(new org.apache.catalina.mbeans.ServerLifecycleListener());
        // add GlobalNamingResource
        DescriptorHelper.registerDescriptor(desc, registry,
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Context");
        desc.setTagClass("org.apache.catalina.core.StandardContext");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardContextSF");
        String exceptions[] = { "available", "configFile", "configured",
                "distributable", "domain", "engineName", "name", "override",
                "publicId", "replaceWelcomeFiles", "sessionTimeout",
                "startupTime", "tldScanTime" };
        for (int i = 0; i < exceptions.length; i++)
            desc.addTransientAttribute(exceptions[i]);

        registry.registerDescription(desc);
        factory = new StandardContextSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);

        StoreDescription listenerdesc = registerDescriptor("Listener",
                LifecycleListener.class);

        String listenerskippables[] = {
                "org.apache.catalina.core.NamingContextListener",
                "org.apache.catalina.startup.ContextConfig", };
        for (int i = 0; i < listenerskippables.length; i++)
            listenerdesc.addTransientChild(listenerskippables[i]);

        StoreDescription realmdesc = registerDescriptor("Realm",
                JAASRealm.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        StoreDescription managerdesc = registerDescriptor("Manager",
                StandardManager.class,
                "org.apache.catalina.storeconfig.ManagerSF", false, false);
        managerdesc.addTransientAttribute("entropy");
        managerdesc.addTransientAttribute("distributable");
        StoreDescription pmanagerdesc = registerDescriptor("Manager",
                PersistentManager.class,
                "org.apache.catalina.storeconfig.PersistentManagerSF", false,
                false);
        pmanagerdesc.addTransientAttribute("entropy");
        pmanagerdesc.addTransientAttribute("distributable");
        DescriptorHelper.registerDescriptor(pmanagerdesc, registry,
                FileStore.class.getName(), "Store", FileStore.class.getName(),
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        DescriptorHelper.registerDescriptor(pmanagerdesc, registry,
                JDBCStore.class.getName(), "Store", JDBCStore.class.getName(),
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        DescriptorHelper.registerNamingDescriptor(desc, registry);
        StoreDescription valvedesc = registerDescriptor("Valve", Valve.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        String skippables[] = {
                "org.apache.catalina.authenticator.BasicAuthenticator",
                "org.apache.catalina.authenticator.DigestAuthenticator",
                "org.apache.catalina.authenticator.FormAuthenticator",
                "org.apache.catalina.authenticator.NonLoginAuthenticator",
                "org.apache.catalina.authenticator.SSLAuthenticator",
                "org.apache.catalina.core.StandardContextValve",
                "org.apache.catalina.valves.CertificatesValve" };
        for (int i = 0; i < skippables.length; i++)
            valvedesc.addTransientChild(skippables[i]);

        StoreDescription resdesc = registerDescriptor("Resources",
                DirContext.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        resdesc.addTransientAttribute("docBase");
        resdesc.addTransientAttribute("allowLinking");
        resdesc.addTransientAttribute("cacheMaxSize");
        resdesc.addTransientAttribute("cacheTTL");
        resdesc.addTransientAttribute("caseSensitive");
        resdesc.addTransientChild(FileDirContext.class.getName());
        resdesc.addTransientChild(ProxyDirContext.class.getName());
        resdesc.addTransientChild(WARDirContext.class.getName());
        standardContext = new StandardContext();
        standardContext.setPath("/myapps");
        standardContext.setDocBase("myapps");

    }
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Context");
        desc.setTagClass("org.apache.catalina.core.StandardContext");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardContextSF");
        String exceptions[] = { "available", "configFile", "configured",
                "distributable", "domain", "engineName", "name", "override",
                "publicId", "replaceWelcomeFiles", "sessionTimeout",
                "startupTime", "tldScanTime" };
        for (int i = 0; i < exceptions.length; i++)
            desc.addTransientAttribute(exceptions[i]);

        registry.registerDescription(desc);
        factory = new StandardContextSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);

        StoreDescription listenerdesc = registerDescriptor("Listener",
                LifecycleListener.class);

        String listenerskippables[] = {
                "org.apache.catalina.core.NamingContextListener",
                "org.apache.catalina.startup.ContextConfig", };
        for (int i = 0; i < listenerskippables.length; i++)
            listenerdesc.addTransientChild(listenerskippables[i]);

        StoreDescription realmdesc = registerDescriptor("Realm",
                JAASRealm.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        StoreDescription managerdesc = registerDescriptor("Manager",
                StandardManager.class,
                "org.apache.catalina.storeconfig.ManagerSF", false, false);
        managerdesc.addTransientAttribute("entropy");
        managerdesc.addTransientAttribute("distributable");
        StoreDescription pmanagerdesc = registerDescriptor("Manager",
                PersistentManager.class,
                "org.apache.catalina.storeconfig.PersistentManagerSF", false,
                false);
        pmanagerdesc.addTransientAttribute("entropy");
        pmanagerdesc.addTransientAttribute("distributable");
        DescriptorHelper.registerDescriptor(pmanagerdesc, registry,
                FileStore.class.getName(), "Store", FileStore.class.getName(),
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        DescriptorHelper.registerDescriptor(pmanagerdesc, registry,
                JDBCStore.class.getName(), "Store", JDBCStore.class.getName(),
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        DescriptorHelper.registerNamingDescriptor(desc, registry);
        StoreDescription valvedesc = registerDescriptor("Valve", Valve.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        String skippables[] = {
                "org.apache.catalina.authenticator.BasicAuthenticator",
                "org.apache.catalina.authenticator.DigestAuthenticator",
                "org.apache.catalina.authenticator.FormAuthenticator",
                "org.apache.catalina.authenticator.NonLoginAuthenticator",
                "org.apache.catalina.authenticator.SSLAuthenticator",
                "org.apache.catalina.core.StandardContextValve",
                "org.apache.catalina.valves.CertificatesValve" };
        for (int i = 0; i < skippables.length; i++)
            valvedesc.addTransientChild(skippables[i]);

        StoreDescription resdesc = registerDescriptor("Resources",
                DirContext.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);
        resdesc.addTransientAttribute("docBase");
        resdesc.addTransientAttribute("allowLinking");
        resdesc.addTransientAttribute("cacheMaxSize");
        resdesc.addTransientAttribute("cacheTTL");
        resdesc.addTransientAttribute("caseSensitive");
        resdesc.addTransientChild(FileDirContext.class.getName());
        resdesc.addTransientChild(ProxyDirContext.class.getName());
        resdesc.addTransientChild(WARDirContext.class.getName());
        standardContext = new StandardContext();
        standardContext.setPath("/myapps");
        standardContext.setDocBase("myapps");

    }
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Engine");
        desc.setTagClass("org.apache.catalina.core.StandardEngine");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardEngineSF");
        desc.addTransientAttribute("domain");
        registry.registerDescription(desc);
        factory = new StandardEngineSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);
        StoreDescription listenerdesc = registerDescriptor("Listener",
                LifecycleListener.class);

        String listenerskippables[] = {
                "org.apache.catalina.core.NamingContextListener",
                "org.apache.catalina.startup.ContextConfig",
                "org.apache.catalina.startup.EngineConfig",
                "org.apache.catalina.startup.HostConfig", };
        for (int i = 0; i < listenerskippables.length; i++)
            listenerdesc.addTransientChild(listenerskippables[i]);

        StoreDescription realmdesc = registerDescriptor("Realm",
                JAASRealm.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", true, false);
        StoreDescription hostdesc = registerDescriptor("Host",
                StandardHost.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", true, false);
        hostdesc.addTransientAttribute("domain");
        StoreDescription valvedesc = registerDescriptor("Valve", Valve.class,
                "org.apache.catalina.storeconfig.StoreFactoryBase", false,
                false);

        String skippables[] = {
                "org.apache.catalina.authenticator.BasicAuthenticator",
                "org.apache.catalina.authenticator.DigestAuthenticator",
                "org.apache.catalina.authenticator.FormAuthenticator",
                "org.apache.catalina.authenticator.NonLoginAuthenticator",
                "org.apache.catalina.authenticator.SSLAuthenticator",
                "org.apache.catalina.core.StandardContextValve",
                "org.apache.catalina.core.StandardEngineValve",
                "org.apache.catalina.core.StandardHostValve",
                "org.apache.catalina.valves.CertificatesValve",
                "org.apache.catalina.valves.ErrorReportValve",
                "org.apache.catalina.valves.RequestListenerValve", };
        for (int i = 0; i < skippables.length; i++)
            valvedesc.addTransientChild(skippables[i]);

        standardEngine = new StandardEngine();
        standardEngine.setName("Catalina");

    }
View Full Code Here

Examples of org.apache.catalina.storeconfig.StoreDescription

     */
    protected void setUp() throws Exception {

        super.setUp();
        registry = new StoreRegistry();
        desc = new StoreDescription();
        desc.setTag("Server");
        desc.setTagClass("org.apache.catalina.core.StandardServer");
        desc.setStandard(true);
        desc
                .setStoreFactoryClass("org.apache.catalina.storeconfig.StandardServerSF");
        registry.registerDescription(desc);
        factory = new StandardServerSF();
        desc.setStoreFactory(factory);
        factory.setRegistry(registry);
        StoreDescription listdesc = registerDescriptor("Listener",
                LifecycleListener.class);
        listdesc
                .addTransientChild("org.apache.catalina.core.NamingContextListener");
        listdesc
                .addTransientChild("org.apache.catalina.mbeans.ServerLifecycleListener");
        standardServer
                .addLifecycleListener(new org.apache.catalina.mbeans.ServerLifecycleListener());
        // add GlobalNamingResource
        DescriptorHelper.registerDescriptor(desc, registry,
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.