我正在使用git轮询来触发jenkins的构建。
我正在使用git plugin 3.0.0
这些天它工作正常,但突然间它开始失败并出现以下错误。使用相同的凭据和git插件,我的其他构建作业正在使用其他git存储库。
Using strategy: Default
[poll] Last Built Revision: Revision 6c3463c502ba01b873b1e7959fe7cb81f3999e2f (origin/master)
using GIT_SSH to set credentials User for GIT/Gerrit
> D:\Git\bin\git.exe ls-remote -h ssh://userid@git.wdf.sap.corp:29418/myapp/myapp.git # timeout=10
ERROR: Timeout after 10 minutes
ERROR: Failed to join a process
org.jvnet.winp.WinpException: Failed to read environment variable table error=299 at .\envvar-cmdline.cpp:201
at org.jvnet.winp.Native.getCmdLineAndEnvVars(Native Method)
at org.jvnet.winp.WinProcess.parseCmdLineAndEnvVars(WinProcess.java:126)
at org.jvnet.winp.WinProcess.getCommandLine(WinProcess.java:102)
at hudson.util.ProcessTree$Windows$1.getArguments(ProcessTree.java:441)
at hudson.plugins.msbuild.MsBuildKillingVeto.vetoProcessKilling(MsBuildKillingVeto.java:55)
at hudson.util.ProcessTree$OSProcess.getVeto(ProcessTree.java:239)
at hudson.util.ProcessTree$Windows$1.killRecursively(ProcessTree.java:422)
at hudson.util.ProcessTree.killAll(ProcessTree.java:142)
at hudson.Proc$LocalProc.destroy(Proc.java:378)
at hudson.Proc$LocalProc.kill(Proc.java:370)
at hudson.Proc$1.run(Proc.java:157)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
答案 0 :(得分:1)
Git民意调查被挂起了。
我重新启动了Jenkins,现在根据轮询日志工作正常。
我们的投票策略不对。我们继续每分钟轮询,这增加了Jenkins服务器的负载,并且线程用完了。 Jenkins目前的重启不是一个可持续的解决方案
我们应该从git轮询转向基于git hook的解决方案,该解决方案就像推送通知一样
检查https://groups.google.com/forum/#!topic/jenkinsci-users/smRQrhb2A-Q 这http://kohsuke.org/2011/12/01/polling-must-die-triggering-jenkins-builds-from-a-git-hook/
欢呼声,
Saurav