The moose likes Ant, Maven and Other Build Tools and the fly likes Maven Sonar plugin... how does it work? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven Sonar plugin... how does it work?" Watch "Maven Sonar plugin... how does it work?" New topic

Maven Sonar plugin... how does it work?

Jayesh A Lalwani
Saloon Keeper

Joined: Jan 17, 2008
Posts: 2746

We are using Maven 3 for building our multi module app, and we had installed Sonar 2.8 and have a sonar build working in our CI environment that would publish the results to the sonar. Unfortunately, that sonar build stopped working. I investigated and I found that we had introduced an unit test that takes a long time to run. the Maven sonar plugin opens a connection to the database server and keeps it open while the test is running. Eventually, the connection times out while the unit test is running, and sonar bombs.

I googled around and it looks like this was a bug in Sonar that was fixed recently. So, I installed SOnar 3.5.1 on a server. I assumed that I had to use a maven sonar 3.5.1 plugin, but all their documentation says that we should put 2.0 in the version number of the plugin. Which is kind of screwy to me. I assumed that the plugin is opening a connection to the database, and unless I don;t upgrade the plugin, I will still get the problem. So, how do I upgrade the plugin

Is my assumption wrong? is the plugin doing like web service calls to the server, and the server opens DB connections?

The test is running right now. I should know whether it really worked or not. It did run some long running tests but hasn;t hit the one it was failing on. So, how does it work?
I agree. Here's the link:
subject: Maven Sonar plugin... how does it work?
It's not a secret anymore!