You have 77 PMD violations maven error [How to Solve]

Maven compilation exception

Failed to execute goal org.apache.maven.plugins:
maven-pmd-plugin:3.8:check (default) 
on project xxx: You have 133 PMD violations. 

Reason: PMD verification is added to Maven to judge whether your code complies with the specification. If it does not comply with the specification, an error will be reported when Maven compiles

Solution: how can this specification be removed? Just execute the following command, which can ignore the PMD check

mvn clean install -Dpmd.skip=true -Dcheckstyle.skip=true

Of course, when Maven compiles, there will be unit test execution, so how to ignore unit test execution?Just execute the following command

mvn clean install -Dmaven.test.skip=true

Therefore, as long as you want to ignore it, you can execute a command directly behind it
in a word:

In order to be compatible with errors, the following methods can be performed:

mvn clean install -Dpmd.skip=true -Dcheckstyle.skip=true -Dmaven.test.skip=true

Read More: