diff --git a/dinky-admin/src/main/java/org/dinky/job/handler/JobRefreshHandler.java b/dinky-admin/src/main/java/org/dinky/job/handler/JobRefreshHandler.java index 3c3cc40612..a3cdb10a02 100644 --- a/dinky-admin/src/main/java/org/dinky/job/handler/JobRefreshHandler.java +++ b/dinky-admin/src/main/java/org/dinky/job/handler/JobRefreshHandler.java @@ -145,22 +145,25 @@ public static boolean refreshJob(JobInfoDetail jobInfoDetail, boolean needSave) if (JobStatus.isTransition(jobInstance.getStatus())) { Long finishTime = TimeUtil.localDateTimeToLong(jobInstance.getFinishTime()); - long duration = Duration.between(jobInstance.getFinishTime(), LocalDateTime.now()).toMinutes(); + long duration = Duration.between(jobInstance.getFinishTime(), LocalDateTime.now()) + .toMinutes(); if (finishTime > 0 && duration < 1) { log.debug("Job is transition: {}->{}", jobInstance.getId(), jobInstance.getName()); isTransition = true; } else if (JobStatus.RECONNECTING.getValue().equals(jobInstance.getStatus())) { - log.debug("Job is not reconnected success at the specified time,set as UNKNOWN: {}->{}", - jobInstance.getId(), jobInstance.getName()); + log.debug( + "Job is not reconnected success at the specified time,set as UNKNOWN: {}->{}", + jobInstance.getId(), + jobInstance.getName()); jobInstance.setStatus(JobStatus.UNKNOWN.getValue()); } } boolean isDone = (JobStatus.isDone(jobInstance.getStatus())) || (TimeUtil.localDateTimeToLong(jobInstance.getFinishTime()) > 0 - && Duration.between(jobInstance.getFinishTime(), LocalDateTime.now()) - .toMinutes() - >= 1); + && Duration.between(jobInstance.getFinishTime(), LocalDateTime.now()) + .toMinutes() + >= 1); isDone = !isTransition && isDone;