@Override public void waitChildren() { JqmClient c = getJqmClient(); Query q = Query.create().setQueryHistoryInstances(false).setQueryLiveInstances(true).setParentId(ji.getId()); while (!c.getJobs(q).isEmpty()) { try { Thread.sleep(1000); handleInstructions(); } catch (InterruptedException e) { Thread.currentThread().interrupt(); break; } } }
@Override public void waitChildren() { JqmClient c = getJqmClient(); Query q = Query.create().setQueryHistoryInstances(false).setQueryLiveInstances(true).setParentId(ji.getId()); while (!c.getJobs(q).isEmpty()) { try { Thread.sleep(1000); handleInstructions(); } catch (InterruptedException e) { Thread.currentThread().interrupt(); break; } } }
Assert.assertEquals(0, TestHelpers.getNonOkCount(cnx)); List<JobInstance> jis = Query.create().setParentId(i).run(); Assert.assertEquals(1, jis.size());