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

[Executor exception] java.lang.VerifyError: Incompatible argument to function

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • grails-plugin, maven-plugin
    • None
    • Ubuntu 12.04.3 LTS, Java-6-openjdk

      Plugins installed:

      Gradle
      Git Client
      Git
      JIRA
      Artifactory
      PWauth
      TestLink
      Join
      Grails

      I recently migrated our jobs directory from an older version of Jenkins to a new Ubuntu 12.04.3 machine running an LTS version of Jenkins ( 1.509.3 ).

      Whenever I try to use the "Build Now" button, the build will fail immediately with this error:

      FATAL: (class: org/apache/commons/codec/binary/Base64OutputStream, method: <init> signature: (Ljava/io/OutputStream;ZI[B)V) Incompatible argument to function

      Strangely, when the SCM detects this build failure and goes in to try and re-build it, it's Successful...even though it still encounters the same error:

      INFO: SCM changes detected in XXXXX. Triggering #50
      Exception in thread "/mnt/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven3.0/bin/mvn -f XXXXXdomain/pom.xml -Dmaven.test.skip=true clean install: stdout copier" java.lang.VerifyError: (class: org/apache/commons/codec/binary/Base64OutputStream, method: <init> signature: (Ljava/io/OutputStream;ZI[B)V) Incompatible argument to function

      INFO: XXXXX #50 main build action completed: SUCCESS

      I've scoured the tickets for any similar issues but I only found this one JENKINS-16542 but it seems a little different. I still went ahead and checked my common-codec jar in the jenkins war and its using v1.6 like it should be.

      Ive tried updating to several different versions of commons-codec in Java to no avail.

      Lastly, i've tried using different versions of Jenkins including the very latest ( 1.531 )

      Let me know if you need anymore information

          [JENKINS-19643] [Executor exception] java.lang.VerifyError: Incompatible argument to function

          Oliver Reeves added a comment -

          I added the "-Xverify:none" option to Maven under JVM options for the build but its still failing.

          Oliver Reeves added a comment - I added the "-Xverify:none" option to Maven under JVM options for the build but its still failing.

          Oliver Reeves added a comment -

          Is there some other method to add that property to the JVM other than through Maven's configuration? I should note that this error is occurring even with jobs that are built solely with Grails.

          Oliver Reeves added a comment - Is there some other method to add that property to the JVM other than through Maven's configuration? I should note that this error is occurring even with jobs that are built solely with Grails.

          Chris Latimer added a comment -

          If you're running Grails under forked mode through maven you can set it within your pom file. See comments on this JIRA for an example: http://jira.grails.org/browse/MAVEN-177. I can't remember if GRAILS_OPTS gets picked up when running Grails with maven in non-forked mode or not, but that's something to possibly try.

          Chris Latimer added a comment - If you're running Grails under forked mode through maven you can set it within your pom file. See comments on this JIRA for an example: http://jira.grails.org/browse/MAVEN-177 . I can't remember if GRAILS_OPTS gets picked up when running Grails with maven in non-forked mode or not, but that's something to possibly try.

          Oliver Reeves added a comment -

          Ill try out both options and report back shortly with my findings. Thanks for the help btw.

          Oliver Reeves added a comment - Ill try out both options and report back shortly with my findings. Thanks for the help btw.

          Radim Kubacki added a comment -

          Same problem here: Linux CentOS 6.4, JDK6u29, Jenkins LTS1.532.1, slaves on the same OS using swarm-client-1.10-jar-with-dependencies.jar

          IMO this is duplicate of JENKINS-20418 - swarm client has a problem with codec library. Class org.apache.commons.codec.binary.Base64OutputStream was present in swarm-client-1.8-jar-with-dependencies.jar but this version is too old to run against Jenkins 1.539.1 (JENKINS-20138). Newer version of swarm misses the codec class. My build passes on master and fails on slave.

          Also the whole dependency management looks fragile: Jenkins has its own codec-1.8 and I see five plugins bundling its own copy so there can be three different versions:

          $ find  plugins/ -name "*codec*jar"
          plugins/violations/WEB-INF/lib/commons-codec-1.4.jar
          plugins/m2-extra-steps/WEB-INF/lib/commons-codec-1.4.jar
          plugins/configurationslicing/WEB-INF/lib/commons-codec-1.4.jar
          plugins/maven-plugin/WEB-INF/lib/commons-codec-1.6.jar
          plugins/git-client/WEB-INF/lib/commons-codec-1.8.jar
          

          Radim Kubacki added a comment - Same problem here: Linux CentOS 6.4, JDK6u29, Jenkins LTS1.532.1, slaves on the same OS using swarm-client-1.10-jar-with-dependencies.jar IMO this is duplicate of JENKINS-20418 - swarm client has a problem with codec library. Class org.apache.commons.codec.binary.Base64OutputStream was present in swarm-client-1.8-jar-with-dependencies.jar but this version is too old to run against Jenkins 1.539.1 ( JENKINS-20138 ). Newer version of swarm misses the codec class. My build passes on master and fails on slave. Also the whole dependency management looks fragile: Jenkins has its own codec-1.8 and I see five plugins bundling its own copy so there can be three different versions: $ find plugins/ -name "*codec*jar" plugins/violations/WEB-INF/lib/commons-codec-1.4.jar plugins/m2-extra-steps/WEB-INF/lib/commons-codec-1.4.jar plugins/configurationslicing/WEB-INF/lib/commons-codec-1.4.jar plugins/maven-plugin/WEB-INF/lib/commons-codec-1.6.jar plugins/git-client/WEB-INF/lib/commons-codec-1.8.jar

          Radim Kubacki added a comment -

          Radim Kubacki added a comment - https://github.com/jenkinsci/swarm-plugin/pull/7 fixes problem for us.

          Ulli Hafner added a comment -

          I integrated https://github.com/jenkinsci/swarm-plugin/pull/8 which basically does the same.

          Ulli Hafner added a comment - I integrated https://github.com/jenkinsci/swarm-plugin/pull/8 which basically does the same.

          Karel Maesen added a comment -

          FYI, I had the same issue. But the swarm-client 1.12-SNAPSHOT (with pull request #8) didn't solve the problem. When I applied PR #7 the problem was resolved.

          Karel Maesen added a comment - FYI, I had the same issue. But the swarm-client 1.12-SNAPSHOT (with pull request #8) didn't solve the problem. When I applied PR #7 the problem was resolved.

          Ulli Hafner added a comment -

          Pull request adds a codec 1.4 dependency which is required to fix the problems with findbugs. Is grails using a newer version?

          Ulli Hafner added a comment - Pull request adds a codec 1.4 dependency which is required to fix the problems with findbugs. Is grails using a newer version?

          Ulli Hafner added a comment -

          Ok, I released a new version with commons codec 1.8.

          Ulli Hafner added a comment - Ok, I released a new version with commons codec 1.8.

            drulli Ulli Hafner
            pi_oliver Oliver Reeves
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: