jenkins gitlab插件1.5.17,当流水线 Trig
2021-12-21 本文已影响0人
87d6dc4b11a7
插件版本:gitlab-plugin:1.5.17
当流水线 Triggered by Gitlab Merge Request 时,出现拉取代码失败的问题
2021-12-20 11:51:14.430 | . java.lang.IllegalStateException: No credentials found for credentialsId:
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.connection.GitLabConnection.getApiToken(GitLabConnection.java:142)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.connection.GitLabConnection.getClient(GitLabConnection.java:118)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.connection.GitLabConnectionConfig.getClient(GitLabConnectionConfig.java:92)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.connection.GitLabConnectionProperty.getClient(GitLabConnectionProperty.java:74)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.connection.GitLabConnectionProperty.getClient(GitLabConnectionProperty.java:85)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.util.CommitStatusUpdater.updateCommitStatus(CommitStatusUpdater.java:51)
2021-12-20 11:51:14.430 | . at com.dabsquared.gitlabjenkins.workflow.GitLabCommitStatusStep$GitLabCommitStatusStepExecution$1.onStart(GitLabCommitStatusStep.java:94)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsBodyExecution.launch(CpsBodyExecution.java:135)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsBodyInvoker.launch(CpsBodyInvoker.java:187)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.DSL$ThreadTaskImpl.lambda$invokeBodiesAndSwitchToAsyncMode$0(DSL.java:660)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsStepContext.withBodyInvokers(CpsStepContext.java:537)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.DSL$ThreadTaskImpl.invokeBodiesAndSwitchToAsyncMode(DSL.java:650)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.DSL$ThreadTaskImpl.eval(DSL.java:615)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:195)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:400)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$400(CpsThreadGroup.java:96)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:312)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:276)
2021-12-20 11:51:14.430 | . at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:67)
2021-12-20 11:51:14.430 | . at java.util.concurrent.FutureTask.run(FutureTask.java:266)
2021-12-20 11:51:14.430 | . at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131)
2021-12-20 11:51:14.430 | . at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
2021-12-20 11:51:14.430 | . at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59)
2021-12-20 11:51:14.430 | . at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
2021-12-20 11:51:14.430 | . at java.util.concurrent.FutureTask.run(FutureTask.java:266)
2021-12-20 11:51:14.430 | . at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
2021-12-20 11:51:14.430 | . at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
2021-12-20 11:51:14.430 | . at java.lang.Thread.run(Thread.java:748)
2021-12-20 11:51:14.430 | . Finished: FAILURE
经搜索发现,这个问题是gitlab-plugin:1.5.17版本的bug,已经修复,需要升级到1.5.22及以后版本。
参考:https://github.com/jenkinsci/gitlab-plugin/issues/1117
https://github.com/jenkinsci/gitlab-plugin/issues/1119
https://github.com/jenkinsci/gitlab-plugin/pull/1129