public abstract static class SchedulerDAO.SchedulerDBStore extends Object
Constructor and Description |
---|
SchedulerDBStore() |
Modifier and Type | Method and Description |
---|---|
abstract void |
createJobInstanceRunTable()
Creates the job instance run table
|
abstract void |
createJobInstanceTable()
Creates the job instance table
|
abstract void |
createJobTable()
Creates the job table
|
List<SchedulerJobInstanceInfo> |
getAllJobInstances(String jobId)
Gets all the instance handle of a job
|
List<SchedulerJobInstanceRun> |
getInstanceRuns(SchedulerJobInstanceState[] states) |
XJob |
getJob(String id)
Gets the job definition
|
SchedulerJobInstanceInfo |
getJobInstanceInfo(String idStr)
Gets the Job instance info corresponding to handle id.
|
List<SchedulerJobHandle> |
getJobs(String username,
SchedulerJobState[] states,
Long starttime,
Long endtime)
Gets all the jobs which match the filter requirements.
|
List<SchedulerJobHandle> |
getJobsByName(String jobname)
Get the job handles given the job name
|
SchedulerJobState |
getJobState(String id)
Gets the job status
|
SchedulerJobInfo |
getSchedulerJobInfo(String idStr)
Gets the Job info object
|
String |
getUser(String id)
Get the user who submitted the job.
|
void |
init(org.apache.commons.dbcp.BasicDataSource ds)
Init the store.
|
int |
insertIntoJobInstanceRunTable(SchedulerJobInstanceRun instanceRun) |
int |
insertIntoJobInstanceTable(SchedulerJobInstanceInfo instanceInfo)
Inserts the job instance info object into job instance table
|
int |
insertIntoJobTable(SchedulerJobInfo jobInfo)
Inserts the Job info object into job table
|
int |
updateJob(String id,
XJob job,
long modifiedOn)
Update the XJob into the job table
|
int |
updateJobInstanceRun(SchedulerJobInstanceRun instanceRun)
Updates the status of a job instance.
|
int |
updateJobStatus(String id,
String status,
long modifiedOn)
Updates the job status into the job table
|
public void init(org.apache.commons.dbcp.BasicDataSource ds)
ds
- public abstract void createJobTable() throws SQLException
SQLException
public abstract void createJobInstanceTable() throws SQLException
SQLException
public abstract void createJobInstanceRunTable() throws SQLException
SQLException
public int insertIntoJobTable(SchedulerJobInfo jobInfo) throws SQLException
jobInfo
- SQLException
public int insertIntoJobInstanceTable(SchedulerJobInstanceInfo instanceInfo) throws SQLException
instanceInfo
- SQLException
public int insertIntoJobInstanceRunTable(SchedulerJobInstanceRun instanceRun) throws SQLException
SQLException
public SchedulerJobInfo getSchedulerJobInfo(String idStr) throws SQLException
idStr
- SQLException
public XJob getJob(String id) throws SQLException
id
- SQLException
public List<SchedulerJobHandle> getJobsByName(String jobname) throws SQLException
jobname
- SQLException
public SchedulerJobState getJobState(String id) throws SQLException
id
- SQLException
public List<SchedulerJobHandle> getJobs(String username, SchedulerJobState[] states, Long starttime, Long endtime) throws SQLException
username
- states
- starttime
- endtime
- SQLException
public int updateJob(String id, XJob job, long modifiedOn) throws SQLException
id
- job
- modifiedOn
- SQLException
public int updateJobStatus(String id, String status, long modifiedOn) throws SQLException
id
- status
- modifiedOn
- SQLException
public SchedulerJobInstanceInfo getJobInstanceInfo(String idStr) throws SQLException
idStr
- SQLException
public int updateJobInstanceRun(SchedulerJobInstanceRun instanceRun) throws SQLException
instanceRun
- SQLException
public List<SchedulerJobInstanceInfo> getAllJobInstances(String jobId) throws SQLException
jobId
- SQLException
public String getUser(String id) throws SQLException
id
- SQLException
public List<SchedulerJobInstanceRun> getInstanceRuns(SchedulerJobInstanceState[] states) throws SQLException
SQLException
Copyright © 2014–2018 Apache Software Foundation. All rights reserved.