Package org.apache.oozie.store

Examples of org.apache.oozie.store.CoordinatorStore.closeTrx()


        catch (Exception e) {
            e.printStackTrace();
            fail("Could not update db.");
        }
        finally {
            store.closeTrx();
        }

        String rerunScope = "2009-12-15T01:00Z" + "::" + "2009-12-17T01:00Z";

        final OozieClient coordClient = LocalOozie.getCoordClient();
View Full Code Here


        CoordinatorActionBean action1 = store1.getCoordinatorAction(actionId1, false);
        assertNotSame(action1.getStatus(), CoordinatorAction.Status.SUCCEEDED);
        CoordinatorActionBean action2 = store1.getCoordinatorAction(actionId2, false);
        assertNotSame(action2.getStatus(), CoordinatorAction.Status.SUCCEEDED);
        store1.commitTrx();
        store1.closeTrx();
    }

    /**
     * Test : rerun <jobId> -date 2009-12-15T01:00Z,2009-12-16T01:00Z,2009-12-17T01:00Z -nocleanup
     * 2009-12-17T01:00Z is not in the action list, Oozie will not tolerate this when comma is used.
View Full Code Here

        catch (Exception e) {
            e.printStackTrace();
            fail("Could not update db.");
        }
        finally {
            store.closeTrx();
        }
        String rerunScope = "2009-12-15T01:00Z,2009-12-16T01:00Z,2009-12-17T01:00Z";
        try {
            final OozieClient coordClient = LocalOozie.getCoordClient();
            coordClient.reRunCoord(jobId, RestConstants.JOB_COORD_RERUN_DATE, rerunScope, false, true);
View Full Code Here

        try {
            addRecordToJobTable(jobId, store);
            addRecordToActionTable(jobId, 1, store);
        }
        finally {
            store.closeTrx();
        }
        new CoordActionReadyCommand(jobId).call();
        checkCoordAction(jobId + "@1");
    }
View Full Code Here

        }
        catch (StoreException se) {
            fail("Action ID " + actionId + " was not stored properly in db");
        }
        finally {
            store.closeTrx();
        }
    }

}
View Full Code Here

            store.rollbackTrx();
            fail("Unable to insert the test job record to table");
            throw se;
        }
        finally {
            store.closeTrx();
        }
    }

    private CoordinatorActionBean checkCoordAction(String actionId) throws StoreException {
        CoordinatorStore store = new CoordinatorStore(false);
View Full Code Here

            store.rollbackTrx();
            fail("Unable to insert the test job record to table");
            throw se;
        }
        finally {
            store.closeTrx();
        }
    }

    private void checkCoordActions(String jobId, int number, CoordinatorJob.Status status) throws StoreException {
        CoordinatorStore store = new CoordinatorStore(false);
View Full Code Here

        catch (Exception e) {
            e.printStackTrace();
            fail("Could not update db.");
        }
        finally {
            store.closeTrx();
        }

        CoordinatorStore store1 = Services.get().get(StoreService.class).getStore(CoordinatorStore.class);
        store1.beginTrx();
        CoordinatorActionBean action1 = store1.getCoordinatorAction(actionId, false);
View Full Code Here

        CoordinatorStore store1 = Services.get().get(StoreService.class).getStore(CoordinatorStore.class);
        store1.beginTrx();
        CoordinatorActionBean action1 = store1.getCoordinatorAction(actionId, false);
        assertEquals(action1.getStatus(), CoordinatorAction.Status.SUCCEEDED);
        store1.commitTrx();
        store1.closeTrx();

        final OozieClient coordClient = LocalOozie.getCoordClient();
        coordClient.reRunCoord(jobId, RestConstants.JOB_COORD_RERUN_ACTION, Integer.toString(actionNum), false, true);

        CoordinatorStore store2 = Services.get().get(StoreService.class).getStore(CoordinatorStore.class);
View Full Code Here

        CoordinatorStore store2 = Services.get().get(StoreService.class).getStore(CoordinatorStore.class);
        store2.beginTrx();
        CoordinatorActionBean action2 = store2.getCoordinatorAction(actionId, false);
        assertNotSame(action2.getStatus(), CoordinatorAction.Status.SUCCEEDED);
        store2.commitTrx();
        store2.closeTrx();
    }

    /**
     * Test : rerun <jobId> -action 1-2 -nocleanup
     *
 
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.