Maven/Tomcat Projects In Eclipse Indigo/3.7

巧了我就是萌 提交于 2019-11-27 03:28:05
samy-delux

Before m2e became an eclipse project the WTP integration shipped with the core module. Now the core module is an eclipse module and the WTP integration is shipped separately. The current Indigo snapshots of m2eclipse-wtp can be found here. I was unable to get any artifacts from this update site however, even though it's listed in the corresponding JIRA issue.

Fortunately, today m2e-wtp was made available through the m2e Marketplace. Just open the eclipse preferences, go to 'Maven' -> 'Discovery' -> 'Open Catalog' and install it.

.

It will work with the lastet version, it's just the .project that is not right.

Simply go into the project properties, make the projet faceted.. tick Dynamic Web Module and you'll get run on server as an option after that.

This will enable the "Run on Server" option, however your problems don't finish there as when you then run it, you'll get a 404.

To fix this, go back into project properties, Deployment assembly.

Delete the WebContent entry (and you can delete the folder in the project later too), and make sure you have the src-main-webapp & src-main-resource folders added.

Bingo.. run the app and it should be fine.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!