You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@paimon.apache.org by ni...@apache.org on 2024/06/11 04:32:54 UTC
(paimon-webui) branch main updated: [Improvement] Remove unnecessary log printing (#320)
This is an automated email from the ASF dual-hosted git repository.
nicholasjiang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/paimon-webui.git
The following commit(s) were added to refs/heads/main by this push:
new 0e3d13cf [Improvement] Remove unnecessary log printing (#320)
0e3d13cf is described below
commit 0e3d13cf128b43c1a97d4ddb2da6699ee1ef44cf
Author: s7monk <34...@users.noreply.github.com>
AuthorDate: Tue Jun 11 12:32:50 2024 +0800
[Improvement] Remove unnecessary log printing (#320)
---
.../apache/paimon/web/server/service/impl/JobServiceImpl.java | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/paimon-web-server/src/main/java/org/apache/paimon/web/server/service/impl/JobServiceImpl.java b/paimon-web-server/src/main/java/org/apache/paimon/web/server/service/impl/JobServiceImpl.java
index adeab17e..889fd275 100644
--- a/paimon-web-server/src/main/java/org/apache/paimon/web/server/service/impl/JobServiceImpl.java
+++ b/paimon-web-server/src/main/java/org/apache/paimon/web/server/service/impl/JobServiceImpl.java
@@ -285,16 +285,20 @@ public class JobServiceImpl extends ServiceImpl<JobMapper, JobInfo> implements J
if (JobStatus.RUNNING.getValue().equals(jobStatus)) {
updateJobStatusAndStartTime(jobId, jobStatus, startTime);
} else if (JobStatus.FINISHED.getValue().equals(jobStatus)
- || JobStatus.CANCELED.getValue().equals(jobStatus)) {
+ || JobStatus.CANCELED.getValue().equals(jobStatus)
+ || JobStatus.FAILED.getValue().equals(jobStatus)) {
LocalDateTime endTime =
job.getEndTime() == null
? LocalDateTime.now()
: job.getEndTime();
updateJobStatusAndEndTime(jobId, jobStatus, endTime);
+ } else {
+ JobInfo jobInfo = new JobInfo();
+ jobInfo.setId(job.getId());
+ jobInfo.setStatus(jobStatus);
+ this.updateById(jobInfo);
}
}
- } else {
- log.warn("Job with ID {} not found in the database.", jobId);
}
}
} catch (Exception e) {