Examples of XmlRpcFileManager


Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fmServer = new XmlRpcFileManager(FILEMGR_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            e.printStackTrace();
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        startDirFile.delete();

    }

    private XmlRpcFileManager startXmlRpcFileManager(int port, String catPath) {
        XmlRpcFileManager fileMgr = null;
       
        // first make sure to load properties for the file manager
        // and make sure to load logging properties as well

        // set the log levels
        System.setProperty("java.util.logging.config.file", new File(
                "./src/main/resources/logging.properties").getAbsolutePath());
       
       
        // first load the example configuration
        try {
            System.getProperties().load(
                    new FileInputStream("./src/main/resources/filemgr.properties"));
        } catch (Exception e) {
            fail(e.getMessage());
        }

        // override the catalog to use: we'll use lucene
        System.setProperty("filemgr.catalog.factory",
                "org.apache.oodt.cas.filemgr.catalog.LuceneCatalogFactory");
        System.setProperty(
                "org.apache.oodt.cas.filemgr.catalog.lucene.idxPath",
                catPath);

        // now override the repo mgr policy
        try {
            System.setProperty(
                    "org.apache.oodt.cas.filemgr.repositorymgr.dirs",
                    "file://"
                            + new File("./src/testdata/ingest/fmpolicy")
                                    .getCanonicalPath());
        } catch (Exception e) {
            fail(e.getMessage());
        }

        // now override the val layer ones
        System.setProperty("org.apache.oodt.cas.filemgr.validation.dirs",
                "file://"
                        + new File("./src/testdata/ingest/fmpolicy")
                                .getAbsolutePath());

        // set up mime repo path
        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fileMgr = new XmlRpcFileManager(port);
        } catch (Exception e) {
            fail(e.getMessage());
        }

        return fileMgr;
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

    }
   
    private void startXmlRpcFileManager() {
        try {
            fmServer = new XmlRpcFileManager(FILEMGR_PORT);
            fmServer.setCatalog(new HsqlDbFriendlyDataSourceCatalogFatory().createCatalog());
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

        System.setProperty(
                "org.apache.oodt.cas.filemgr.mime.type.repository", new File(
                        "./src/main/resources/mime-types.xml").getAbsolutePath());

        try {
            fm = new XmlRpcFileManager(FM_PORT);
        } catch (Exception e) {
            fail(e.getMessage());
        }
    }
View Full Code Here

Examples of org.apache.oodt.cas.filemgr.system.XmlRpcFileManager

      // Test success case.
      System.setProperty("filemgr.catalog.factory", "");
      System.setProperty("filemgr.repository.factory", "");
      int port = 9876;
      XmlRpcFileManager filemgr = new XmlRpcFileManager(port);
      String filemgrUrl = "http://localhost:" + port;
      pgeMetadata = createStrictMock(PgeMetadata.class);
      expect(pgeMetadata.getMetadata(PgeTaskMetKeys.QUERY_FILE_MANAGER_URL))
            .andReturn(filemgrUrl);
      replay(pgeMetadata);

      assertEquals(filemgrUrl, FileStager.createFileManagerClient(pgeMetadata)
            .getFileManagerUrl().toString());
      verify(pgeMetadata);
      filemgr.shutdown();
   }
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.