Alexandre T
Alexandre T

Reputation: 658

Which JDK's release should I use when coding a sonar plugin?

I'm currently coding a plugin for sonar ( custom rules ) . Which JDK and API should I use in order to be compatible for teh majority of sonar instances ? JDK6 ?

Thanks for your response

Upvotes: 1

Views: 950

Answers (3)

Juned Ahsan
Juned Ahsan

Reputation: 68715

From the Sonar website

Prerequisite

The only prerequisite for running Sonar is to have Java (Oracle JRE 6 onwards) installed on your machine.

Check more details here

Upvotes: 4

Alexandre Victoor
Alexandre Victoor

Reputation: 3104

As said above you can use Java6. Indeed you must use Java6. When a sonar analysis is launched, the launcher of the analysis (sonar runner or maven) will use your sonar instance as a plugin repository. This means that each jar plugins will be downloaded on the machine performing the analysis. Then each plugin will be asked if it should be executed or not. Hence, if a plugin is built using Java7, you need to run sonar using Java7 and you also need to run any analysis with Java7, even if this plugin is disabled.

Upvotes: 1

Ashish
Ashish

Reputation: 14707

You can use Java 6 onwards It is also mentioned in the SONAR web site.

Upvotes: 2

Related Questions