@Test(priority = 1) public void testStoreJob() throws Exception { XJob job = getTestJob(); long currentTime = System.currentTimeMillis(); jobHandle = new SchedulerJobHandle(UUID.randomUUID()); SchedulerJobInfo info = new SchedulerJobInfo(jobHandle, job, "lens", SchedulerJobState.NEW, currentTime, currentTime); schedulerDAO.storeJob(info); XJob outJob = schedulerDAO.getJob(info.getId()); Assert.assertEquals(job, outJob); }
public int storeJob(SchedulerJobInfo jobInfo) { try { return store.insertIntoJobTable(jobInfo); } catch (SQLException e) { log.error("Error while storing the jobInfo for {}", jobInfo.getId().getHandleIdString(), e); return 0; } }
SchedulerDAO { public int storeJob(SchedulerJobInfo jobInfo) { try { return store.insertIntoJobTable(jobInfo); } catch (SQLException e) { log.error("Error while storing the jobInfo for {}", jobInfo.getId().getHandleIdString(), e); return 0; } } }
SchedulerDAO { public int storeJob(SchedulerJobInfo jobInfo) { try { return store.insertIntoJobTable(jobInfo); } catch (SQLException e) { log.error("Error while storing the jobInfo for {}", jobInfo.getId().getHandleIdString(), e); return 0; } } SchedulerDAO(Configuration conf); }
SchedulerDAO { public int storeJob(SchedulerJobInfo jobInfo) { try { return store.insertIntoJobTable(jobInfo); } catch (SQLException e) { log.error("Error while storing the jobInfo for {}", jobInfo.getId().getHandleIdString(), e); return 0; } } SchedulerDAO(Configuration conf); int storeJob(SchedulerJobInfo jobInfo); SchedulerJobInfo getSchedulerJobInfo(SchedulerJobHandle id); XJob getJob(SchedulerJobHandle id); String getUser(SchedulerJobHandle id); SchedulerJobState getJobState(SchedulerJobHandle id); int updateJob(SchedulerJobInfo info); int updateJobStatus(SchedulerJobInfo info); int storeJobInstance(SchedulerJobInstanceInfo instanceInfo); int storeJobInstanceRun(SchedulerJobInstanceRun instanceRun); SchedulerJobInstanceInfo getSchedulerJobInstanceInfo(SchedulerJobInstanceHandle id); int updateJobInstanceRun(SchedulerJobInstanceRun instanceRun); List<SchedulerJobInstanceInfo> getJobInstances(SchedulerJobHandle id); List<SchedulerJobHandle> getJobs(String username, Long startTime, Long endTime,
    SchedulerJobState... jobStates); List<SchedulerJobHandle> getJob(String jobName); List<SchedulerJobInstanceRun> getInstanceRuns(SchedulerJobInstanceState... states); }
SchedulerDAO { public int storeJob(SchedulerJobInfo jobInfo) { try { return store.insertIntoJobTable(jobInfo); } catch (SQLException e) { log.error("Error while storing the jobInfo for {}", jobInfo.getId().getHandleIdString(), e); return 0; } } SchedulerDAO(Configuration conf); int storeJob(SchedulerJobInfo jobInfo); SchedulerJobInfo getSchedulerJobInfo(SchedulerJobHandle id); XJob getJob(SchedulerJobHandle id); String getUser(SchedulerJobHandle id); SchedulerJobState getJobState(SchedulerJobHandle id); int updateJob(SchedulerJobInfo info); int updateJobStatus(SchedulerJobInfo info); int storeJobInstance(SchedulerJobInstanceInfo instanceInfo); int storeJobInstanceRun(SchedulerJobInstanceRun instanceRun); SchedulerJobInstanceInfo getSchedulerJobInstanceInfo(SchedulerJobInstanceHandle id); int updateJobInstanceRun(SchedulerJobInstanceRun instanceRun); List<SchedulerJobInstanceInfo> getJobInstances(SchedulerJobHandle id); List<SchedulerJobHandle> getJobs(String username, Long startTime, Long endTime,
    SchedulerJobState... jobStates); List<SchedulerJobHandle> getJob(String jobName); List<SchedulerJobInstanceRun> getInstanceRuns(SchedulerJobInstanceState... states);  }