Search code examples
javamavenpmd

How to know which PMD rule fails?


Maven-pmd-plugin used in the project. When I try to deploy the project, it fails with the following error:

Caused by: org.apache.maven.plugin.MojoFailureException: PMD check threshold has been set to severity level 'error' - detected 1 violation(s) at that (or greater than that) level and 'failOnViolation' is true - failing the build

How can I know which rule is fail? What violation is found?

Executing Maven with -e or -X does not help.


Solution

  • There should be a HTML report generated in target/site/pmd.html that lists detected issues (issue description and line).