Skip to content

Commit

Permalink
save progress
Browse files Browse the repository at this point in the history
  • Loading branch information
liweinan committed Dec 3, 2024
1 parent d6be965 commit 907af1e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ public final class JdbcRepository extends AbstractPersistentRepository {

private static final String SELECT_ALL_JOB_EXECUTIONS = "select-all-job-executions";
private static final String SELECT_JOB_EXECUTIONS_BY_JOB_INSTANCE_ID = "select-job-executions-by-job-instance-id";
private static final String SELECT_JOB_EXECUTIONS_BY_TIMEOUT_SECONDS = "select-job-executions-by-timeout-seconds";
private static final String SELECT_RUNNING_JOB_EXECUTIONS_BY_JOB_NAME = "select-running-job-executions-by-job-name";
private static final String SELECT_JOB_EXECUTIONS_BY_JOB_NAME = "select-job-executions-by-job-name";
private static final String SELECT_JOB_EXECUTION = "select-job-execution";
Expand Down Expand Up @@ -653,6 +654,8 @@ public List<JobExecution> getJobExecutions(final JobInstance jobInstance) {
// todo
@Override
public List<JobExecution> getTimeoutJobExecutions(JobInstance jobInstance, Long timeoutSeconds) {


return List.of();
}

Expand Down
3 changes: 3 additions & 0 deletions jberet-core/src/main/resources/sql/jberet-sql.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ insert-job-instance = INSERT INTO JOB_INSTANCE(JOBNAME, APPLICATIONNAME) VALUES(

select-all-job-executions = SELECT * FROM JOB_EXECUTION
select-job-executions-by-job-instance-id = SELECT * FROM JOB_EXECUTION WHERE JOBINSTANCEID=? ORDER BY JOBEXECUTIONID

select-job-executions-by-timeout-seconds = SELECT * FROM JOB_EXECUTION WHERE lastupdatedtime + ? < now()

select-job-execution = SELECT * FROM JOB_EXECUTION WHERE JOBEXECUTIONID=?
select-running-job-executions-by-job-name = SELECT JOB_EXECUTION.JOBEXECUTIONID FROM JOB_EXECUTION \
INNER JOIN JOB_INSTANCE ON JOB_EXECUTION.JOBINSTANCEID=JOB_INSTANCE.JOBINSTANCEID \
Expand Down

0 comments on commit 907af1e

Please sign in to comment.