Search code examples
javamavenpluginsyamlstatic-code-analysis

Plugin suitable for static code validation with custom rule in maven


We are looking for some efficient solution for the following need: We need to have static analysis of code of our java app. It should find all occurences of someMthod() call in entire app and validate passed argument against properties or yaml file (it should check if parameter passed to someMethod() exists in conf.yaml). It would be ideal if it could be a plugin fired during maven compile phase. Anybody used or know about tool/plugin which can be used here?


Solution

  • This sounds like a great candidate to make your own plugin.

    Read about maven, mojo and build lifecycle.

    https://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html