版权声明:本文为博主原创文章,但知识无界。 https://blog.csdn.net/haohaizijhz/article/details/77879636
also this is unrelated to the plugin, sonarqube has updated the default version of the sonar-maven-plugin to version 3.2. This requires java 8.
To solve the issue you need to update the JAVA_HOME to version 1.8 or use older version of sonar-maven-plugin, example:
export JAVA_HOME="/Library/Java/JavaVirtualMachines/jdk1.8.0_45.jdk/Contents/Home/"
or
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>sonar-maven-plugin</artifactId>
<version>2.6</version>
</plugin>