Package org.apache.oodt.cas.workflow.repository

Examples of org.apache.oodt.cas.workflow.repository.WorkflowRepositoryFactory


     */
    public XmlRpcWorkflowManager(int port) throws Exception {
        Class engineFactoryClass = null, repositoryFactoryClass = null;

        WorkflowEngineFactory engineFactory = null;
        WorkflowRepositoryFactory repoFactory = null;

        // load properties from workflow manager properties file, if specified
        if (System.getProperty("org.apache.oodt.cas.workflow.properties") != null) {
            String configFile = System
                    .getProperty("org.apache.oodt.cas.workflow.properties");
            LOG.log(Level.INFO,
                    "Loading Workflow Manager Configuration Properties from: ["
                            + configFile + "]");
            System.getProperties().load(
                    new FileInputStream(new File(configFile)));
        }

        String engineClassStr = System
                .getProperty("workflow.engine.factory",
                        "org.apache.oodt.cas.workflow.engine.DataSourceWorkflowEngineFactory");
        String repositoryClassStr = System
                .getProperty("workflow.repo.factory",
                        "org.apache.oodt.cas.workflow.repository.DataSourceWorkflowRepositoryFactory");

        try {
            engineFactoryClass = Class.forName(engineClassStr);
            engineFactory = (WorkflowEngineFactory) engineFactoryClass
                    .newInstance();
            engine = engineFactory.createWorkflowEngine();
        } catch (ClassNotFoundException e) {
            e.printStackTrace();
            throw new Exception("Unable to load workflow engine factory class "
                    + engineClassStr);
        }

        webServerPort = port;

        // set the corresponding workflow manager url
        engine.setWorkflowManagerUrl(safeGetUrlFromString("http://"
                + getHostname() + ":" + this.webServerPort));

        try {
            repositoryFactoryClass = Class.forName(repositoryClassStr);
            repoFactory = (WorkflowRepositoryFactory) repositoryFactoryClass
                    .newInstance();
            repo = repoFactory.createRepository();
        } catch (ClassNotFoundException e) {
            e.printStackTrace();
            throw new Exception(
                    "Unable to load workflow repository factory class "
                            + repositoryClassStr);
View Full Code Here


     */
    public XmlRpcWorkflowManager(int port) throws Exception {
        Class engineFactoryClass = null, repositoryFactoryClass = null;

        WorkflowEngineFactory engineFactory = null;
        WorkflowRepositoryFactory repoFactory = null;

        // load properties from workflow manager properties file, if specified
        if (System.getProperty("org.apache.oodt.cas.workflow.properties") != null) {
            String configFile = System
                    .getProperty("org.apache.oodt.cas.workflow.properties");
            LOG.log(Level.INFO,
                    "Loading Workflow Manager Configuration Properties from: ["
                            + configFile + "]");
            System.getProperties().load(
                    new FileInputStream(new File(configFile)));
        }

        String engineClassStr = System
                .getProperty("workflow.engine.factory",
                        "org.apache.oodt.cas.workflow.engine.DataSourceWorkflowEngineFactory");
        String repositoryClassStr = System
                .getProperty("workflow.repo.factory",
                        "org.apache.oodt.cas.workflow.repository.DataSourceWorkflowRepositoryFactory");

        try {
            engineFactoryClass = Class.forName(engineClassStr);
            engineFactory = (WorkflowEngineFactory) engineFactoryClass
                    .newInstance();
            engine = engineFactory.createWorkflowEngine();
        } catch (ClassNotFoundException e) {
            e.printStackTrace();
            throw new Exception("Unable to load workflow engine factory class "
                    + engineClassStr);
        }

        webServerPort = port;

        // set the corresponding workflow manager url
        engine.setWorkflowManagerUrl(safeGetUrlFromString("http://"
                + getHostname() + ":" + this.webServerPort));

        try {
            repositoryFactoryClass = Class.forName(repositoryClassStr);
            repoFactory = (WorkflowRepositoryFactory) repositoryFactoryClass
                    .newInstance();
            repo = repoFactory.createRepository();
        } catch (ClassNotFoundException e) {
            e.printStackTrace();
            throw new Exception(
                    "Unable to load workflow repository factory class "
                            + repositoryClassStr);
View Full Code Here

TOP

Related Classes of org.apache.oodt.cas.workflow.repository.WorkflowRepositoryFactory

Copyright © 2018 www.massapicom. 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.