Jenkins extension for SonarQube 2.16 causes java.lang.UnsupportedOperationException

Hi,

after updating from version 2.15 to 2.16 on Jenkins 2.414.2.2-rolling there were problems when
disabling / enabling freestyle jobs that are using Sonarqube analysis build step.

Error while serving https://jenkins/job/xxx/job/xxx/job/xxx/job/xxx/disable
java.lang.UnsupportedOperationException: Refusing to marshal okhttp3.OkHttpClient for security reasons; see https://www.jenkins.io/redirect/class-filter/
  at hudson.util.XStream2$BlacklistedTypesConverter.marshal(XStream2.java:643)
  at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68)
  at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:59)
  at com.thoughtworks.xstream.core.AbstractReferenceMarshaller$1.convertAnother(AbstractReferenceMarshaller.java:83)
  at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:283)
  at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:270)
Caused: java.lang.RuntimeException: Failed to serialize hudson.plugins.sonar.client.HttpClient#okHttpClient for class hudson.plugins.sonar.client.HttpClient

After downgrade to 2.15 the problems are gone.

Gilbert

1 Like

Hello Gilbert,

Thank you for the report, this issue has also been reported on Jenkins’ issue tracker JENKINS-72201.
A ticket has been created on our side and should be fixed for the 2.17 release SONARJNKNS-369. You can find more details on the issue there.

Eric

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.