0

I have added the sonar task in my build .xml but i am getting the following error please advise how to overcome from this..

Hi Folks,

I haver added the sonar task but now getting the following exceptio pls advise how to overcome from this..

[11:08:29]sonar:sonar
[11:08:29]Apache Ant(TM) version 1.8.4 compiled on May 22 2012
[11:08:29]Sonar Ant Task version: 1.0
[11:08:29]Loaded from: file:/popt/papp/glacier/buildAgent-8.0.3/work/abcr/lib/thirdparty/sonar/sonar-ant-task-1.0.jar
[11:08:29]Sonar work directory: /opt/app/abcr/buildAgent-8.0.3/work/abcer/build
[11:08:29]Sonar server: https://sonar-3.dts.fm.rbsgrp.net
[11:08:29]org.sonar.batch.bootstrapper.BootstrapException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
[11:08:29]Process exited with code 1
[11:08:29]Ant output
[11:08:29]  at com.sun.net.ssl.internal.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:106)
[11:08:29]  at com.sun.net.ssl.internal.ssl.Handshaker.processLoop(Handshaker.java:495)
[11:08:29]  at com.sun.net.ssl.internal.ssl.Handshaker.process_record(Handshaker.java:433)
[11:08:29]  at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:877)
[11:08:29]  at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1089)
[11:08:29]  at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1116)
[11:08:29]  at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1100)
[11:08:29]  at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:402)
[11:08:29]  at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:170)
[11:08:29]  at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:934)
[11:08:29]  at java.net.URLConnection.getContent(URLConnection.java:682)
[11:08:29]  at sun.net.www.protocol.https.HttpsURLConnectionImpl.getContent(HttpsURLConnectionImpl.java:406)
[11:08:29]  at org.sonar.batch.bootstrapper.Bootstrapper.remoteContent(Bootstrapper.java:123)
[11:08:29]  at org.sonar.batch.bootstrapper.Bootstrapper.getServerVersion(Bootstrapper.java:69)

1 Answers1

0

This looks like a TLS certification issue. Depending on the issuer of the certificate for server sonar-3.dts.fm.rbsgrp.net, you will have to add the required certificate - or the root certificate for the issuing CA - to the TrustStore of the JVM used by the Ant task.

See Digital Certificate: How to import .cer file in to .truststore file using? for more details on how to add the required certificate into your TrustStore.

Community
  • 1
  • 1
Mithfindel
  • 4,553
  • 1
  • 23
  • 32