Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.0:shade


Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.0:shade (default) on project QMServer: Execution default of goal org.apache.maven.plugins:maven-shade-plugin:2.0:shade failed: A required class was missing while executing org.apache.maven.plugins:maven-shade-plugin:2.0:shade: org/sonatype/aether/graph/DependencyNode

 

使用eclipse Maven 在構建的時候出現這個錯,可能是eclipse里的maven插件的版本更新之后,相應的POM.xml文件沒有更新,只需要把version里的版本升高就行了。我升到了2.1.當然如果你的eclipse里的maven插件版本不是最新的,但是卻用了最新的POM.xml,也是有可能造成這些錯誤的,反正調節版本就OK

            <plugin>

                <groupId>org.apache.maven.plugins</groupId>

                <artifactId>maven-shade-plugin</artifactId>

                <version>2.0</version>我在這里把2.0改為了2.1

                <executions>

                    <execution>

                        <phase>package</phase>

                        <goals>

                            <goal>shade</goal>

                        </goals>

                        <configuration>

                            <transformers>

                                <transformer

            ---

                                </transformer>

                            </transformers>

                        </configuration>

                    </execution>

                </executions>

            </plugin>


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM