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

java.lang.ClassNotFoundException: javax.annotation.CheckForNull

    Details

    • Similar Issues:
    • Released As:
      Jenkins 2.237

      Description

      In the logs, i see a lot of class not found:

      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    | 2020-04-15 18:07:54.686+0000 [id=15]       WARNING j.t.i.j.MissingClassTelemetry#reportException: Added a missed class for missing class telemetry. Class: javax.annotation.Nullable
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    | java.lang.ClassNotFoundException: javax.annotation.Nullable
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.util.AntClassLoader.findClassInComponents(AntClassLoader.java:1387)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.util.AntClassLoader.findClass(AntClassLoader.java:1342)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.util.AntClassLoader.loadClass(AntClassLoader.java:1089)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.Class.forName0(Native Method)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.Class.forName(Class.java:398)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.generics.factory.CoreReflectionFactory.makeNamedType(CoreReflectionFactory.java:114)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:125)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.annotation.AnnotationParser.parseSig(AnnotationParser.java:440)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.annotation.AnnotationParser.parseAnnotation2(AnnotationParser.java:242)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.annotation.AnnotationParser.parseAnnotation(AnnotationParser.java:227)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.annotation.AnnotationParser.parseParameterAnnotations2(AnnotationParser.java:185)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/sun.reflect.annotation.AnnotationParser.parseParameterAnnotations(AnnotationParser.java:162)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.reflect.Executable.parseParameterAnnotations(Executable.java:78)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.reflect.Executable.sharedGetParameterAnnotations(Executable.java:551)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at java.base/java.lang.reflect.Method.getParameterAnnotations(Method.java:712)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Function$InstanceFunction.getParameterAnnotations(Function.java:423)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:176)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:145)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.MetaClass$11.doDispatch(MetaClass.java:535)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:747)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.invoke(Stapler.java:878)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.MetaClass$4.doDispatch(MetaClass.java:280)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:747)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.invoke(Stapler.java:878)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.MetaClass$4.doDispatch(MetaClass.java:280)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:747)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.invoke(Stapler.java:878)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.MetaClass$4.doDispatch(MetaClass.java:280)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:747)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.invoke(Stapler.java:878)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.invoke(Stapler.java:676)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.kohsuke.stapler.Stapler.service(Stapler.java:238)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:755)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:154)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.security.ResourceDomainFilter.doFilter(ResourceDomainFilter.java:76)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:151)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.telemetry.impl.UserLanguages$AcceptLanguageFilter.doFilter(UserLanguages.java:128)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:151)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:157)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:159)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.UnwrapSecurityExceptionFilter.doFilter(UnwrapSecurityExceptionFilter.java:51)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at jenkins.security.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:122)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:142)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271)
      jenkins_jenkins.1.zgbcwngkyxe4@ramipont    |    at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)

      I'm using the official 2.231-jdk11 docker image with  couple of additional packages (https://hub.docker.com/layers/jenkins/jenkins/2.231-jdk11/images/sha256-61c6599741200705274f9841d6d101d1abbce1e599c5bc98414308d88ffccc0d?context=explore).

        Attachments

          Issue Links

            Activity

            Hide
            juergen_zimmermann Juergen Zimmermann added a comment -
            FYI: The classes "javax.annotation.Nonnull" and "javax.annotation.CheckForNull" are included e.g. in the Maven artifact "com.google.code.findbugs:annotations". Maybe this could be the cause.
            Show
            juergen_zimmermann Juergen Zimmermann added a comment - FYI: The classes "javax.annotation.Nonnull" and "javax.annotation.CheckForNull" are included e.g. in the Maven artifact "com.google.code.findbugs:annotations". Maybe this could be the cause.
            Hide
            nrayapati Naresh Rayapati added a comment -

            We are also facing the same issue. Here is gist with startup log and list of plugins if that would be helpful to debug more. Thank you!

            https://gist.github.com/nrayapati/3cbf84213be6d492d334be1802f65349

            Show
            nrayapati Naresh Rayapati added a comment - We are also facing the same issue. Here is gist with startup log and list of plugins if that would be helpful to debug more. Thank you! https://gist.github.com/nrayapati/3cbf84213be6d492d334be1802f65349
            Hide
            danielbeck Daniel Beck added a comment - - edited

            Only affects Jenkins on JDK11.

            Show
            danielbeck Daniel Beck added a comment - - edited Only affects Jenkins on JDK11.
            Hide
            enys Edward Nys added a comment -

            Affected too, on jdk11

            Show
            enys Edward Nys added a comment - Affected too, on jdk11
            Hide
            mramonleon Ramon Leon added a comment -

            I analyzed the log and it's safe to ignore the CNFE thrown in CoreReflectionFactory#makeNamedType. So I've added this location to the ignored places.

            In addition, I added a way to avoid printing twice a warning for the same class name in the log, to avoid polluting it on new cases.

            The PR: https://github.com/jenkinsci/jenkins/pull/4712

            Show
            mramonleon Ramon Leon added a comment - I analyzed the log and it's safe to ignore the CNFE thrown in CoreReflectionFactory#makeNamedType . So I've added this location to the ignored places. In addition, I added a way to avoid printing twice a warning for the same class name in the log, to avoid polluting it on new cases. The PR: https://github.com/jenkinsci/jenkins/pull/4712

              People

              • Assignee:
                mramonleon Ramon Leon
                Reporter:
                cghislai charly ghislain
              • Votes:
                5 Vote for this issue
                Watchers:
                12 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: