Package org.apache.oozie.command.coord

Examples of org.apache.oozie.command.coord.CoordSubmitCommand.call()


        conf.set("MINUTES", "1");
        injectKerberosInfo(conf);
        CoordSubmitCommand sc = new CoordSubmitCommand(conf, "UNIT_TESTING");

        try {
            sc.call();
            fail("Coord job submission should fail with reserved variable definitions.");
        }
        catch (CommandException ce) {

        }
View Full Code Here


                CoordSubmitXCommand submit = new CoordSubmitXCommand(conf, getAuthToken());
                jobId = submit.call();
            }
            else {
                CoordSubmitCommand submit = new CoordSubmitCommand(conf, getAuthToken());
                jobId = submit.call();
            }
            return jobId;
        }
        catch (CommandException ex) {
            throw new CoordinatorEngineException(ex);
View Full Code Here

                CoordSubmitXCommand submit = new CoordSubmitXCommand(true, conf, getAuthToken());
                jobId = submit.call();
            }
            else {
                CoordSubmitCommand submit = new CoordSubmitCommand(true, conf, getAuthToken());
                jobId = submit.call();
            }
            return jobId;
        }
        catch (CommandException ex) {
            throw new CoordinatorEngineException(ex);
View Full Code Here

     */
    @Override
    public String submitJob(Configuration conf, boolean startJob) throws CoordinatorEngineException {
        CoordSubmitCommand submit = new CoordSubmitCommand(conf, getAuthToken());
        try {
            String jobId = submit.call();
            return jobId;
        }
        catch (CommandException ex) {
            throw new CoordinatorEngineException(ex);
        }
View Full Code Here

     */
    @Override
    public String dryrunSubmit(Configuration conf, boolean startJob) throws CoordinatorEngineException {
        CoordSubmitCommand submit = new CoordSubmitCommand(true, conf, getAuthToken());
        try {
            String jobId = submit.call();
            return jobId;
        }
        catch (CommandException ex) {
            throw new CoordinatorEngineException(ex);
        }
View Full Code Here

        conf.set(OozieClient.COORDINATOR_APP_PATH, appPath);
        conf.set(OozieClient.USER_NAME, getTestUser());
        conf.set(OozieClient.GROUP_NAME, "other");
        injectKerberosInfo(conf);
        CoordSubmitCommand sc = new CoordSubmitCommand(conf, "UNIT_TESTING");
        String jobId = sc.call();

        assertEquals(jobId.substring(jobId.length() - 2), "-C");
        CoordinatorJobBean job = checkCoordJobs(jobId);
        if (job != null) {
            assertEquals(job.getTimeout(), Services.get().getConf().getInt(
View Full Code Here

        if (withDefaults) {
            String defaults = "<configuration><property><name>startTime</name>" +
                              "<value>2009-02-01T01:00Z</value></property></configuration>";
            writeToFile(defaults, getTestCaseDir() + File.separator + CoordSubmitCommand.CONFIG_DEFAULT);
            String jobId = sc.call();
            assertEquals(jobId.substring(jobId.length() - 2), "-C");
        }
        else {
            try {
                sc.call();
View Full Code Here

            String jobId = sc.call();
            assertEquals(jobId.substring(jobId.length() - 2), "-C");
        }
        else {
            try {
                sc.call();
                fail();
            }
            catch (CommandException ex) {
                assertEquals(ErrorCode.E1004, ex.getErrorCode());
            }
View Full Code Here

        conf.set(OozieClient.COORDINATOR_APP_PATH, appPath);
        conf.set(OozieClient.USER_NAME, getTestUser());
        conf.set(OozieClient.GROUP_NAME, "other");
        injectKerberosInfo(conf);
        CoordSubmitCommand sc = new CoordSubmitCommand(conf, "UNIT_TESTING");
        String jobId = sc.call();

        assertEquals(jobId.substring(jobId.length() - 2), "-C");
        checkCoordJobs(jobId);
    }
View Full Code Here

        conf.set(OozieClient.COORDINATOR_APP_PATH, appPath);
        conf.set(OozieClient.USER_NAME, getTestUser());
        conf.set(OozieClient.GROUP_NAME, "other");
        injectKerberosInfo(conf);
        CoordSubmitCommand sc = new CoordSubmitCommand(conf, "UNIT_TESTING");
        String jobId = sc.call();

        assertEquals(jobId.substring(jobId.length() - 2), "-C");
        checkCoordJobs(jobId);
    }
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.