Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-69248

Recent Git-client plugin releases are incompatible with Java 8

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor Minor
    • trilead-api-plugin
    • None

      Git-client plugin version 3.11.2 is incompatible with Jenkins workers running Java 8, and leads to the following sort of error:

      13:40:43 java.lang.UnsupportedClassVersionError: com/trilead/ssh2/ServerHostKeyVerifier has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
      13:40:43 	at java.lang.ClassLoader.defineClass1(Native Method)
      13:40:43 	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
      13:40:43 	at java.lang.ClassLoader.defineClass(ClassLoader.java:635)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadClassFile(RemoteClassLoader.java:458)
      13:40:43 Caused: java.lang.UnsupportedClassVersionError: Failed to load com.trilead.ssh2.ServerHostKeyVerifier
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadClassFile(RemoteClassLoader.java:460)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadRemoteClass(RemoteClassLoader.java:300)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadWithMultiClassLoader(RemoteClassLoader.java:269)
      13:40:43 	at hudson.remoting.RemoteClassLoader.findClass(RemoteClassLoader.java:228)
      13:40:43 	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
      13:40:43 	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
      13:40:43 	at java.lang.ClassLoader.defineClass1(Native Method)
      13:40:43 	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
      13:40:43 	at java.lang.ClassLoader.defineClass(ClassLoader.java:635)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadClassFile(RemoteClassLoader.java:458)
      13:40:43 Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to <HOSTNAME>
      13:40:43 		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1784)
      13:40:43 		at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
      13:40:43 		at hudson.remoting.Channel.call(Channel.java:1000)
      13:40:43 		at hudson.FilePath.act(FilePath.java:1194)
      13:40:43 		at hudson.FilePath.act(FilePath.java:1183)
      13:40:43 		at org.jenkinsci.plugins.gitclient.Git.getClient(Git.java:140)
      13:40:43 		at hudson.plugins.git.GitSCM.createClient(GitSCM.java:916)
      13:40:43 		at hudson.plugins.git.GitSCM.createClient(GitSCM.java:847)
      13:40:43 		at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1297)
      13:40:43 		at hudson.scm.SCM.checkout(SCM.java:540)
      13:40:43 		at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
      13:40:43 		at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
      13:40:43 		at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
      13:40:43 		at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
      13:40:43 		at hudson.model.Run.execute(Run.java:1897)
      13:40:43 		at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
      13:40:43 		at hudson.model.ResourceController.execute(ResourceController.java:101)
      13:40:43 		at hudson.model.Executor.run(Executor.java:442)
      13:40:43 Caused: java.lang.UnsupportedClassVersionError: Failed to load org.jenkinsci.plugins.gitclient.verifier.AbstractJGitHostKeyVerifier
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadClassFile(RemoteClassLoader.java:460)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadRemoteClass(RemoteClassLoader.java:292)
      13:40:43 	at hudson.remoting.RemoteClassLoader.loadWithMultiClassLoader(RemoteClassLoader.java:269)
      13:40:43 	at hudson.remoting.RemoteClassLoader.findClass(RemoteClassLoader.java:228)
      13:40:43 	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
      13:40:43 	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
      13:40:43 	at java.lang.Class.getDeclaredMethods0(Native Method)
      13:40:43 	at java.lang.Class.privateGetDeclaredMethods(Class.java:2729)
      13:40:43 	at java.lang.Class.getDeclaredMethod(Class.java:2156)
      13:40:43 	at java.io.ObjectStreamClass.getPrivateMethod(ObjectStreamClass.java:1643)
      13:40:43 	at java.io.ObjectStreamClass.access$1700(ObjectStreamClass.java:79)
      13:40:43 	at java.io.ObjectStreamClass$3.run(ObjectStreamClass.java:520)
      13:40:43 	at java.io.ObjectStreamClass$3.run(ObjectStreamClass.java:494)
      13:40:43 	at java.security.AccessController.doPrivileged(Native Method)
      13:40:43 	at java.io.ObjectStreamClass.<init>(ObjectStreamClass.java:494)
      13:40:43 	at java.io.ObjectStreamClass.lookup(ObjectStreamClass.java:391)
      13:40:43 	at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:681)
      13:40:43 	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1942)
      13:40:43 	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1808)
      13:40:43 	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1942)
      13:40:43 	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1808)
      13:40:43 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2099)
      13:40:43 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
      13:40:43 	at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2344)
      13:40:43 	at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2268)
      13:40:43 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2126)
      13:40:43 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
      13:40:43 	at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2344)
      13:40:43 	at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2268)
      13:40:43 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2126)
      13:40:43 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
      13:40:43 	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
      13:40:43 	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
      13:40:43 	at hudson.remoting.UserRequest.deserialize(UserRequest.java:289)
      13:40:43 	at hudson.remoting.UserRequest.perform(UserRequest.java:189)
      13:40:43 	at hudson.remoting.UserRequest.perform(UserRequest.java:54)
      13:40:43 	at hudson.remoting.Request$2.run(Request.java:376)
      13:40:43 	at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78)
      13:40:43 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      13:40:43 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      13:40:43 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      13:40:43 	at java.lang.Thread.run(Thread.java:748)
      13:40:43 Caused: java.io.IOException: Remote call on <HOSTNAME> failed
      13:40:43 	at hudson.remoting.Channel.call(Channel.java:1004)
      13:40:43 	at hudson.FilePath.act(FilePath.java:1194)
      13:40:43 	at hudson.FilePath.act(FilePath.java:1183)
      13:40:43 	at org.jenkinsci.plugins.gitclient.Git.getClient(Git.java:140)
      13:40:43 	at hudson.plugins.git.GitSCM.createClient(GitSCM.java:916)
      13:40:43 	at hudson.plugins.git.GitSCM.createClient(GitSCM.java:847)
      13:40:43 	at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1297)
      13:40:43 	at hudson.scm.SCM.checkout(SCM.java:540)
      13:40:43 	at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
      13:40:43 	at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
      13:40:43 	at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
      13:40:43 	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
      13:40:43 	at hudson.model.Run.execute(Run.java:1897)
      13:40:43 	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
      13:40:43 	at hudson.model.ResourceController.execute(ResourceController.java:101)
      13:40:43 	at hudson.model.Executor.run(Executor.java:442) 

      We are unable to upgrade Java on these workers (they alone are pinned to Java 8 because we still need it around for a couple of things). We solved the issue by downgrading to version 3.11.0, but of course we would like to have the security fixes. Would it be possible to recompile the plugin such that it retains compatibility with Java 8?

       

      Thanks,

      Adam Compton

            markewaite Mark Waite
            acompton_slack Adam Compton
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: