mulesoft-catalyst / mule-sonarqube-plugin

The Mule SonarQube Plugin provides the capability to do code inspecting and taking project metrics from a mule project using SonarQube.
The Unlicense
48 stars 69 forks source link

Plugin not working on SonarQube 9.2 #41

Closed gtuvshin closed 2 years ago

gtuvshin commented 2 years ago

Hello Contributers,

I'm trying to install the plugin on the latest version of SonarQube 9.2. However, after installation, Sonarqube web doesn't start properly and shows a message [SonarQube is offline]. I checked the log file and found the following error. It seems that the format of the rules doesn't match the current one. XML extension has been removed from XML setting before installing the plugin. Is this because the current version of the plugin is not compatible with SonarQube 9.2?

Thank you.

2022.02.01 01:49:29 ERROR web[][o.s.s.p.Platform] Background initialization failed. Stopping SonarQube
java.lang.RuntimeException: unexpected element (uri:"", local:"html"). Expected elements are <{}rule>,<{}ruleset>,<{}rulestore>
        at com.mulesoft.services.tools.sonarqube.rule.MuleRulesDefinition.createRepository(MuleRulesDefinition.java:78)
        at com.mulesoft.services.tools.sonarqube.rule.MuleRulesDefinition.define(MuleRulesDefinition.java:49)
tulasikamodula commented 2 years ago

Try copying the Mule 3 rules file as well to the plugins folder. Looks like there is some reference thats causing the server not to start up.

gtuvshin commented 2 years ago

Thanks for reply. I put the Mule 3 rules and Mule 4 rules together to the plugins folder and got above error. Before that, I had placed only the Mule 4 rule, and it showed an error that Mule 3 was missing as you mentioned.

tulasikamodula commented 2 years ago

FYI: I just used the plugin yesterday with SonarQube 9.3 and it is working fine after I copied both the rule sets.

gtuvshin commented 2 years ago

@tulasikamodula I just found out that rule-3 was broken due to using unproper link. It worked fine now after download again original file. Thanks for hint. It helped me a lot.