将可以在Eclipse中使用的Dynamic Web项目转换为Maven项目后,构建尚未完成

时间:2019-07-01 09:39:20

标签: spring maven

我试图按照link复制spring程序,动态Web项目运行良好,但是我想将其转换为maven结构并运行相同的程序。 尝试右键单击该项目 我试图做更新项目,然后试图做Maven生成在控制台中出现以下错误

INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ SpringMvcHelloWorldProgram ---
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory C:\Users\ragupat\eclipse-workspace\SpringMvcHelloWorldProgram\src\main\resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ SpringMvcHelloWorldProgram ---
[INFO] No sources to compile
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ SpringMvcHelloWorldProgram ---
[INFO] Not copying test resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ SpringMvcHelloWorldProgram ---
[INFO] Not compiling test sources
[INFO] 
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ SpringMvcHelloWorldProgram ---
[INFO] Tests are skipped.
[INFO] 
[INFO] --- maven-war-plugin:2.2:war (default-war) @ SpringMvcHelloWorldProgram ---
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.thoughtworks.xstream.core.util.Fields (file:/C:/Users/ragupat/.m2/repository/com/thoughtworks/xstream/xstream/1.3.1/xstream-1.3.1.jar) to field java.util.Properties.defaults
WARNING: Please consider reporting this to the maintainers of com.thoughtworks.xstream.core.util.Fields
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
[INFO] Packaging webapp
[INFO] Assembling webapp [SpringMvcHelloWorldProgram] in [C:\Users\ragupat\eclipse-workspace\SpringMvcHelloWorldProgram\target\SpringMvcHelloWorldProgram-0.0.1-SNAPSHOT]
[INFO] Processing war project
[INFO] Copying webapp resources [C:\Users\ragupat\eclipse-workspace\SpringMvcHelloWorldProgram\src\main\webapp]
[INFO] Webapp assembled in [149 msecs]
[INFO] Building war: C:\Users\ragupat\eclipse-workspace\SpringMvcHelloWorldProgram\target\SpringMvcHelloWorldProgram-0.0.1-SNAPSHOT.war
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.390 s
[INFO] Finished at: 2019-07-01T13:18:14+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war (default-war) on project SpringMvcHelloWorldProgram: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in update mode) -> [Help 1]
[ERROR] 

0 个答案:

没有答案