Hi all, I’ve been trying to deploy a java custom check, and for that I’ve began with the source code of SuppressWarningsCheck, modifying it slightly so instead a comma separated list it could also read a regular expression. The code is the same sans the aforementioned change.
I’ve got my rule registrar, plugin defintiion, etc. The unit tests are also doing fine.
However, when launching a mvn sonar:sonar, I’ve stumbled upon a weird issue, the reportIssue method isn’t reporting anything. Following the chain call, it all goes ok until storage.store(this) on line 151 of DefaultIssue.java: storage class corresponds to InMemorySensorStorage, instead of DefaultSensorStorage, which is the class that the original check gets injected, which also registers the issue so that SQ is able to show it.
So, clearly there’s something missing on my plugin, but I fail to see what and/or where. The issue happens both on a local / corporate SQ 10.1 CE server.
FTR I’ve been following https://github.com/SonarSource/sonar-java/blob/master/docs/CUSTOM_RULES_101.md#rule-activation in order to get the plugin running.