利用eclipse新建的java web项目没有部署描述符web.xml文件怎么办?

 

利用eclipse新建的java web项目没有部署描述符web.xml文件怎么办?

解决办法:

1、右键项目名称-》Java EE Tools-》Generate Deployment descriptor stub

     即可生成web.xml文件。

或者

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <version>2.6</version>
                <configuration>
                    <failOnMissingWebXml>false</failOnMissingWebXml>
                </configuration>
            </plugin>
原文地址:https://www.cnblogs.com/chengjun/p/9308077.html