Examples of closeTrx()


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

            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

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

            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

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

        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();
        waitFor(120 * 1000, new Predicate() {
            @Override
            public boolean evaluate() throws Exception {
                CoordinatorAction bean = coordClient.getCoordActionInfo(actionId);
                return (bean.getStatus() == CoordinatorAction.Status.WAITING || bean.getStatus() == CoordinatorAction.Status.READY);
View Full Code Here

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

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

        try {
            final OozieClient coordClient = LocalOozie.getCoordClient();
            coordClient.reRunCoord(jobId, RestConstants.JOB_COORD_RERUN_ACTION, Integer.toString(actionNum), false,
View Full Code Here

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

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

    /**
     * Tests functionality of the coord rerun for backward support is true. </p> Insert a coordinator job with SUCCEEDED
     * and coordinator actions with pending false, but one of action is FAILED.
View Full Code Here

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

        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

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

        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

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

        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

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

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

        String rerunScope = Integer.toString(actionNum1) + "-" + Integer.toString(actionNum2);

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

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

        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> -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.