From a415d773806a7cc9cfe42376375b051e299ef23a Mon Sep 17 00:00:00 2001 From: sawyersong Date: Fri, 17 Dec 2021 17:40:10 +0800 Subject: [PATCH 1/2] =?UTF-8?q?bug:=20=E6=9E=84=E5=BB=BA=E9=95=9C=E5=83=8F?= =?UTF-8?q?=E6=89=AB=E6=8F=8F=E8=BE=93=E5=85=A5=E5=AD=97=E6=AE=B5=E7=BC=BA?= =?UTF-8?q?=E5=A4=B1fix=20#5818?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: sawyersong --- .../com/tencent/devops/dockerhost/services/DockerService.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/ci/core/dockerhost/biz-dockerhost/src/main/kotlin/com/tencent/devops/dockerhost/services/DockerService.kt b/src/backend/ci/core/dockerhost/biz-dockerhost/src/main/kotlin/com/tencent/devops/dockerhost/services/DockerService.kt index 1ff4f7014fc..c5caa46b134 100644 --- a/src/backend/ci/core/dockerhost/biz-dockerhost/src/main/kotlin/com/tencent/devops/dockerhost/services/DockerService.kt +++ b/src/backend/ci/core/dockerhost/biz-dockerhost/src/main/kotlin/com/tencent/devops/dockerhost/services/DockerService.kt @@ -261,7 +261,7 @@ class DockerService @Autowired constructor( future == null -> Pair(Status.NO_EXISTS, "") future.isDone -> { when { - future.get().first -> Pair(Status.SUCCESS, "") + future.get().first -> Pair(Status.SUCCESS, future.get().second ?: "") else -> Pair(Status.FAILURE, future.get().second ?: "") } } From b46f8ce348ee51fcb7b7b2afd1aa5f34a5b47a47 Mon Sep 17 00:00:00 2001 From: sawyersong Date: Mon, 20 Dec 2021 10:45:19 +0800 Subject: [PATCH 2/2] =?UTF-8?q?bug:=20=E6=9E=84=E5=BB=BA=E9=95=9C=E5=83=8F?= =?UTF-8?q?=E6=89=AB=E6=8F=8F=E8=BE=93=E5=85=A5=E5=AD=97=E6=AE=B5=E7=BC=BA?= =?UTF-8?q?=E5=A4=B1fix=20#5818?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: sawyersong --- .../devops/dispatch/docker/dao/PipelineDockerBuildDao.kt | 2 +- .../devops/dispatch/docker/service/DockerHostBuildService.kt | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/dao/PipelineDockerBuildDao.kt b/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/dao/PipelineDockerBuildDao.kt index 206c35338bd..523838df960 100644 --- a/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/dao/PipelineDockerBuildDao.kt +++ b/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/dao/PipelineDockerBuildDao.kt @@ -193,7 +193,7 @@ class PipelineDockerBuildDao { return dslContext.selectFrom(this) .where(STATUS.eq(2)) .and(DOCKER_IP.notEqual("")) - .and(UPDATED_TIME.lessOrEqual(timestampSubDay(2))) + .and(UPDATED_TIME.lessOrEqual(timestampSubDay(7))) .fetch() } } diff --git a/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/service/DockerHostBuildService.kt b/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/service/DockerHostBuildService.kt index 132bdedef42..a3ef70f9187 100644 --- a/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/service/DockerHostBuildService.kt +++ b/src/backend/ci/core/dispatch-docker/biz-dispatch-docker/src/main/kotlin/com/tencent/devops/dispatch/docker/service/DockerHostBuildService.kt @@ -251,7 +251,6 @@ class DockerHostBuildService @Autowired constructor( * 每天执行一次,更新大于七天状态还是running的pool,以及大于七天状态还是running的build history,并主动关机 */ @Scheduled(initialDelay = 120 * 1000, fixedDelay = 3600 * 24 * 1000) - @Deprecated("this function is deprecated!") fun updateTimeoutPoolTask() { var message = "" val redisLock = RedisLock(redisOperation, "update_timeout_pool_task_nogkudla", 5L)