Skip to content

Commit d774224

Browse files
committed
::lipstick:
1 parent fc8f68d commit d774224

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

openjob-server/openjob-server-repository/src/main/java/io/openjob/server/repository/repository/DelayInstanceRepository.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ public interface DelayInstanceRepository extends JpaRepository<DelayInstance, Lo
3737
* @param deleted deleted
3838
* @return List
3939
*/
40-
@Query(value = "SELECT new io.openjob.server.repository.dto.DelayInstanceTotalDTO(d.topic, count(d.id)) from DelayInstance as d where d.topic in (?1) and d.status in (?2) and d.deleted=?3 group by d.topic")
40+
@Query(value = "SELECT new io.openjob.server.repository.dto.DelayInstanceTotalDTO(d.topic, count(d.id)) from DelayInstance as d "
41+
+ "where d.topic in (?1) and d.status in (?2) and d.deleted=?3 group by d.topic")
4142
List<DelayInstanceTotalDTO> getDelayTotalCount(List<String> topics, List<Integer> statuses, Integer deleted);
4243

4344
/**
@@ -49,6 +50,8 @@ public interface DelayInstanceRepository extends JpaRepository<DelayInstance, Lo
4950
DelayInstance findByTaskId(String taskId);
5051

5152
/**
53+
* Update status by task id
54+
*
5255
* @param taskId taskId
5356
* @param status status
5457
* @return Integer

openjob-worker/openjob-worker-core/src/main/java/io/openjob/worker/OpenjobWorker.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,11 @@ public synchronized void init() throws Exception {
8282
}, 0, retryInterval, TimeUnit.SECONDS);
8383
}
8484

85+
/**
86+
* Do initialize
87+
*
88+
* @return Boolean
89+
*/
8590
public synchronized Boolean doInitialize() {
8691
try {
8792
// Initialize worker config.

openjob-worker/openjob-worker-core/src/main/java/io/openjob/worker/init/WorkerShutdown.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ public WorkerShutdown(OpenjobWorker openjobWorker) {
2626
this.openjobWorker = openjobWorker;
2727
}
2828

29+
/**
30+
* Init
31+
*/
2932
public void init() {
3033
// Already initialized
3134
if (this.isInit.get()) {

0 commit comments

Comments
 (0)