• Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major Major
    • analysis-core-plugin
    • None
    • Jenkins 1.584
      Checkstyle plugin 3.39

      When making API requests for jobs with "depth=1" or greater, Jenkins return a 500 error (the "Oops!" page) with a stack trace.

      I ran a test job several times with different plugin combinations and it crashes when I use the Checkstyle plugin.

      This seems related to JENKINS-24458 and JENKINS-23409

      javax.servlet.ServletException: java.lang.IllegalArgumentException
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:778)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
      at org.kohsuke.stapler.MetaClass$4.doDispatch(MetaClass.java:210)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
      at org.kohsuke.stapler.MetaClass$12.dispatch(MetaClass.java:390)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
      at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:248)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:631)
      at org.kohsuke.stapler.Stapler.service(Stapler.java:225)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
      at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:686)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1494)
      at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:96)
      at hudson.plugins.greenballs.GreenBallFilter.doFilter(GreenBallFilter.java:58)
      at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:99)
      at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter$1.call(ScmSyncConfigurationFilter.java:46)
      at hudson.plugins.scm_sync_configuration.ScmSyncConfigurationDataProvider.provideRequestDuring(ScmSyncConfigurationDataProvider.java:103)
      at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter.doFilter(ScmSyncConfigurationFilter.java:42)
      at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:99)
      at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:88)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
      at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:48)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
      at hudson.security.UnwrapSecurityExceptionFilter.doFilter(UnwrapSecurityExceptionFilter.java:51)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at jenkins.security.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:117)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:142)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at jenkins.security.BasicHeaderProcessor.doFilter(BasicHeaderProcessor.java:86)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
      at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:67)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
      at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
      at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:164)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
      at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:46)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
      at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
      at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1474)
      at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:499)
      at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
      at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:533)
      at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
      at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
      at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:428)
      at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
      at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
      at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
      at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
      at org.eclipse.jetty.server.Server.handle(Server.java:370)
      at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:489)
      at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:949)
      at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1011)
      at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:644)
      at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
      at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
      at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:668)
      at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
      at winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at java.lang.Thread.run(Thread.java:744)
      Caused by: java.lang.IllegalArgumentException
      at sun.reflect.GeneratedMethodAccessor454.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.kohsuke.stapler.export.MethodProperty.getValue(MethodProperty.java:66)
      at org.kohsuke.stapler.export.Property.writeTo(Property.java:116)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:190)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:185)
      at org.kohsuke.stapler.export.Property.writeValue(Property.java:241)
      at org.kohsuke.stapler.export.Property.writeValue(Property.java:187)
      at org.kohsuke.stapler.export.Property.writeValue(Property.java:139)
      at org.kohsuke.stapler.export.Property.writeTo(Property.java:116)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:190)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:185)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:185)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:185)
      at org.kohsuke.stapler.export.Model.writeNestedObjectTo(Model.java:185)
      at org.kohsuke.stapler.export.Model.writeTo(Model.java:157)
      at org.kohsuke.stapler.ResponseImpl.serveExposedBean(ResponseImpl.java:267)
      at hudson.model.Api.doPython(Api.java:216)
      at sun.reflect.GeneratedMethodAccessor161.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:298)
      at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:161)
      at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:96)
      at org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:120)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
      ... 74 more

          [JENKINS-25167] API requests crash with depth greater than 0

          João Vale created issue -

          Ulli Hafner added a comment -

          From the stacktrace I see:

          at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter$1.call(ScmSyncConfigurationFilter.java:46)
          at hudson.plugins.scm_sync_configuration.ScmSyncConfigurationDataProvider.provideRequestDuring(ScmSyncConfigurationDataProvider.java:103)
          at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter.doFilter(ScmSyncConfigurationFilter.java:42)
          

          Is this a plugin you have installed?

          Ulli Hafner added a comment - From the stacktrace I see: at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter$1.call(ScmSyncConfigurationFilter.java:46) at hudson.plugins.scm_sync_configuration.ScmSyncConfigurationDataProvider.provideRequestDuring(ScmSyncConfigurationDataProvider.java:103) at hudson.plugins.scm_sync_configuration.extensions.ScmSyncConfigurationFilter.doFilter(ScmSyncConfigurationFilter.java:42) Is this a plugin you have installed?
          Ulli Hafner made changes -
          Component/s New: core [ 15593 ]
          Component/s Original: checkstyle [ 15512 ]

          Ulli Hafner added a comment - - edited

          @kohsuke (or any core developer): Would it be possible to add an exception message? It is hard to see what is broken if there is just this exception without any details...

          Ulli Hafner added a comment - - edited @ kohsuke (or any core developer): Would it be possible to add an exception message? It is hard to see what is broken if there is just this exception without any details...
          Ulli Hafner made changes -
          Assignee Original: Ulli Hafner [ drulli ]
          Ulli Hafner made changes -
          Link New: This issue duplicates JENKINS-25054 [ JENKINS-25054 ]

          João Vale added a comment -

          Yes, that's the "SCM Sync configuration" plugin, but I don't think that that's the culprit. If I run the job as I had it before upgrading Jenkins, it fails. If I remove, for example, the Cobertura plugin call, it still fails. If I just remove Checkstyle, it succeeds.

          It might however be some kind of interaction between SCM sync and checkstyle? Doesn't sound likely, but I guess it's not impossible. Do you want me to test it without the SCM Sync plugin? Don't think it will make much of a difference, but I can try and do it if you think it's an useful sanity check.

          João Vale added a comment - Yes, that's the "SCM Sync configuration" plugin, but I don't think that that's the culprit. If I run the job as I had it before upgrading Jenkins, it fails. If I remove, for example, the Cobertura plugin call, it still fails. If I just remove Checkstyle, it succeeds. It might however be some kind of interaction between SCM sync and checkstyle? Doesn't sound likely, but I guess it's not impossible. Do you want me to test it without the SCM Sync plugin? Don't think it will make much of a difference, but I can try and do it if you think it's an useful sanity check.

          Daniel Beck added a comment -

          SCM Sync appears to be just another filter here. The error is with the job data that is being serialized. JENKINS-25054 appears to be relevant here, that user was able to determine the issue was caused by use of the Warnings plugin. Maybe a similar strategy of determining the cause works for you as well.

          Daniel Beck added a comment - SCM Sync appears to be just another filter here. The error is with the job data that is being serialized. JENKINS-25054 appears to be relevant here, that user was able to determine the issue was caused by use of the Warnings plugin. Maybe a similar strategy of determining the cause works for you as well.

          João Vale added a comment -

          That's pretty close to what I did: I created a copy of the job (through the UI), disabled publishers and ran the job until I found a combination that didn't throw an error. It was simple enough as it is just a Freestlye job that fetches data from git, has a shell build step and calls the Cobertura and Checkstyle plugins.

          These were the combinations:

          • both plugins: fails with the above trace
          • only Cobertura: succeeds
          • only Checkstyle: fails with the above trace

          João Vale added a comment - That's pretty close to what I did: I created a copy of the job (through the UI), disabled publishers and ran the job until I found a combination that didn't throw an error. It was simple enough as it is just a Freestlye job that fetches data from git, has a shell build step and calls the Cobertura and Checkstyle plugins. These were the combinations: both plugins: fails with the above trace only Cobertura: succeeds only Checkstyle: fails with the above trace

          Daniel Beck added a comment -

          Right, already mentioned in the original report. My apologies. Reassigning this specific issue to checkstyle.

          Core (or rather Stapler) could use better error reporting, will try to look into that. That's an improvement though, not a bug.

          Daniel Beck added a comment - Right, already mentioned in the original report. My apologies. Reassigning this specific issue to checkstyle. Core (or rather Stapler) could use better error reporting, will try to look into that. That's an improvement though, not a bug.
          Daniel Beck made changes -
          Component/s New: checkstyle [ 15512 ]
          Component/s Original: core [ 15593 ]

            Unassigned Unassigned
            jvale João Vale
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: