The “sonar-ws” maven dependency

Hi,

I’m currently writing a Sonar Plugin and wondering if someone could clarify a point regarding the use of the org.sonar.api.server.ws.LocalConnector for making calls to the built-in Sonar WS without http.

The per java doc on LocalConnector, the inclusion of the “sonar-ws” dependency is needed but I can’t set the scope to “provided”.

Am I ok to include this dependency on my plugin project with a “compile” scope? Does using it violate any contract / internal API?

<dependency>
  <groupId>org.sonarsource.sonarqube</groupId>
  <artifactId>sonar-ws</artifactId>
  <version>${sonar.version}</version>
</dependency>

Thanks.

Hi @nuno_castilho78 ,

Thanks for asking.

I confirm that using the compile scope should be ok.

Cheers,
Aurélien

1 Like

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