Skip to content

Commit

Permalink
fix: 修复扫描执行服务拉取镜像失败 #2766
Browse files Browse the repository at this point in the history
* fix: 修复扫描执行服务拉取镜像失败 #2766

* fix: 修复扫描执行服务拉取镜像失败 #2766

* fix: 调整制品分析日志级别 #2766
  • Loading branch information
cnlkl authored Nov 21, 2024
1 parent 01210ad commit ee1d45b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ open class SubtaskPoller(
open fun dispatch() {
executionClusterService.list().forEach {
executor.execute {
logger.info("cluster [${it.name}] start to dispatch subtask")
logger.debug("cluster [${it.name}] start to dispatch subtask")
dispatcherCache.get(it.name).dispatch()
logger.info("cluster [${it.name}] dispatch finished")
logger.debug("cluster [${it.name}] dispatch finished")
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ abstract class SubtaskPushDispatcher<T : ExecutionCluster>(

override fun dispatch() {
if (scanService.peek(executionCluster.name) == null) {
logger.info("cluster [${executionCluster.name}] has no subtask to dispatch")
logger.debug("cluster [${executionCluster.name}] has no subtask to dispatch")
return
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ object DockerUtils {
password: String?,
) {
val images = listImagesCmd().exec()
val exists = images.any { image ->
image.repoTags.any { it == tag }
}
val exists = images?.any { image ->
image.repoTags?.any { it == tag } ?: false
} ?: false
if (exists) {
return
}
Expand Down

0 comments on commit ee1d45b

Please sign in to comment.