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

org.kohsuke.stapler.NoStaplerConstructorException using custom tools versions

XMLWordPrintable

      When changing a custom tool installation for using versions, the following stack trace is shown after saving, and the config is not updated.

       

      org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class com.cwctravel.hudson.plugins.extended_choice_parameter.ExtendedChoiceParameterDefinition
          at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:247)
          at org.kohsuke.stapler.RequestImpl.instantiate(RequestImpl.java:764)
          at org.kohsuke.stapler.RequestImpl.access$200(RequestImpl.java:83)
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:678)
      Caused: java.lang.IllegalArgumentException: Failed to instantiate class com.cwctravel.hudson.plugins.extended_choice_parameter.ExtendedChoiceParameterDefinition from {"name":"7ZIP_VERSION","description":"Version of 7-Zip","parameterGroup":{"value":"0","type":"PT_SINGLE_SELECT","visibleItemCount":"5","multiSelectDelimiter":"","quoteValue":false,"propertySource":{"value":"0","propertyValue":"16.04,16.05,16.06"},"defaultPropertySource":{"value":"0","defaultPropertyValue":"16.04"},"descriptionPropertySource":{"value":"0","descriptionPropertyValue":"16.04 Version"}}}
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:680)
          at org.kohsuke.stapler.RequestImpl.bindJSON(RequestImpl.java:478)
          at org.kohsuke.stapler.RequestImpl.instantiate(RequestImpl.java:777)
      Caused: java.lang.IllegalArgumentException: Failed to convert the versionsListSource parameter of the constructor public com.synopsys.arc.jenkinsci.plugins.customtools.versions.ToolVersionConfig(com.cwctravel.hudson.plugins.extended_choice_parameter.ExtendedChoiceParameterDefinition)
          at org.kohsuke.stapler.RequestImpl.instantiate(RequestImpl.java:779)
          at org.kohsuke.stapler.RequestImpl.access$200(RequestImpl.java:83)
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:678)
      Caused: java.lang.IllegalArgumentException: Failed to instantiate class com.synopsys.arc.jenkinsci.plugins.customtools.versions.ToolVersionConfig from {"versionsListSource":{"name":"7ZIP_VERSION","description":"Version of 7-Zip","parameterGroup":{"value":"0","type":"PT_SINGLE_SELECT","visibleItemCount":"5","multiSelectDelimiter":"","quoteValue":false,"propertySource":{"value":"0","propertyValue":"16.04,16.05,16.06"},"defaultPropertySource":{"value":"0","defaultPropertyValue":"16.04"},"descriptionPropertySource":{"value":"0","descriptionPropertyValue":"16.04 Version"}}}}
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:680)
          at org.kohsuke.stapler.RequestImpl.bindJSON(RequestImpl.java:478)
          at org.kohsuke.stapler.RequestImpl.instantiate(RequestImpl.java:777)
      Caused: java.lang.IllegalArgumentException: Failed to convert the toolVersion parameter of the constructor public com.cloudbees.jenkins.plugins.customtools.CustomTool(java.lang.String,java.lang.String,java.util.List,java.lang.String,com.synopsys.arc.jenkinsci.plugins.customtools.LabelSpecifics[],com.synopsys.arc.jenkinsci.plugins.customtools.versions.ToolVersionConfig,java.lang.String)
          at org.kohsuke.stapler.RequestImpl.instantiate(RequestImpl.java:779)
          at org.kohsuke.stapler.RequestImpl.access$200(RequestImpl.java:83)
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:678)
      Caused: java.lang.IllegalArgumentException: Failed to instantiate class com.cloudbees.jenkins.plugins.customtools.CustomTool from {"name":"7-Zip","exportedPaths":"","home":"","additionalVariables":"","labelSpecifics":{"label":"os:windows","exportedPaths":".","additionalVars":""},"toolVersion":{"versionsListSource":{"name":"7ZIP_VERSION","description":"Version of 7-Zip","parameterGroup":{"value":"0","type":"PT_SINGLE_SELECT","visibleItemCount":"5","multiSelectDelimiter":"","quoteValue":false,"propertySource":{"value":"0","propertyValue":"16.04,16.05,16.06"},"defaultPropertySource":{"value":"0","defaultPropertyValue":"16.04"},"descriptionPropertySource":{"value":"0","descriptionPropertyValue":"16.04 Version"}}}},"properties":{"stapler-class-bag":"true","hudson-tools-InstallSourceProperty":{"installers":{"label":"os:windows","url":"http://nexus.ae.hz.lbbw.sko.de:8081/repository/jenkins-tools/de/7zip/7zip/16.04/7zip-16.04-win64.zip","subdir":"","stapler-class<span class="code-quote">":"hudson.tools.ZipExtractionInstaller","$class<span class="code-quote">":"hudson.tools.ZipExtractionInstaller"}}}}
          at org.kohsuke.stapler.RequestImpl$TypePair.convertJSON(RequestImpl.java:680)
          at org.kohsuke.stapler.RequestImpl.bindJSON(RequestImpl.java:478)
          at org.kohsuke.stapler.RequestImpl.bindJSON(RequestImpl.java:474)
          at org.kohsuke.stapler.RequestImpl.bindJSONToList(RequestImpl.java:519)
          at hudson.tools.ToolDescriptor.configure(ToolDescriptor.java:140)
          at jenkins.tools.GlobalToolConfiguration.configureDescriptor(GlobalToolConfiguration.java:101)
          at jenkins.tools.GlobalToolConfiguration.configure(GlobalToolConfiguration.java:90)
          at jenkins.tools.GlobalToolConfiguration.doConfigure(GlobalToolConfiguration.java:79)
          at java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:627)
          at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:343)
          at org.kohsuke.stapler.interceptor.RequirePOST$Processor.invoke(RequirePOST.java:52)
          at org.kohsuke.stapler.PreInvokeInterceptedFunction.invoke(PreInvokeInterceptedFunction.java:26)
          at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:184)
          at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:117)
          at org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:129)
          at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
          at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:715)
      Caused: javax.servlet.ServletException
          at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:765)
          at org.kohsuke.stapler.Stapler.invoke(Stapler.java:845)
          at org.kohsuke.stapler.MetaClass$10.dispatch(MetaClass.java:374)
          at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:715)
          at org.kohsuke.stapler.Stapler.invoke(Stapler.java:845)
          at org.kohsuke.stapler.Stapler.invoke(Stapler.java:649)
          at org.kohsuke.stapler.Stapler.service(Stapler.java:238)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:135)
          at hudson.plugins.greenballs.GreenBallFilter.doFilter(GreenBallFilter.java:59)
          at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:132)
          at net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:237)
          at net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:209)
          at net.bull.javamelody.PluginMonitoringFilter.doFilter(PluginMonitoringFilter.java:88)
          at org.jvnet.hudson.plugins.monitoring.HudsonMonitoringFilter.doFilter(HudsonMonitoringFilter.java:113)
          at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:132)
          at hudson.plugins.audit_trail.AuditTrailFilter.doFilter(AuditTrailFilter.java:95)
          at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:132)
          at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:126)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:80)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          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:93)
          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:171)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:49)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:82)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at org.kohsuke.stapler.DiagnosticThreadNameFilter.doFilter(DiagnosticThreadNameFilter.java:30)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108)
          at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:632)
          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
          at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:620)
          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:349)
          at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:1110)
          at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
          at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:785)
          at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1425)
          at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
          at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
          at java.lang.Thread.run(Thread.java:745)
      

            oleg_nenashev Oleg Nenashev
            kriusd K R
            Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: