Eclipse WTP不会发布Maven依赖项 [英] Eclipse WTP not publishing Maven dependencies

查看:114
本文介绍了Eclipse WTP不会发布Maven依赖项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用Eclipse Indigo和Tomcat服务器设置一个基本的hello world项目。我用一个简单的servlet创建了一个动态项目。测试了servlet,并且工作正常。然后我启用了Maven支持,并添加了logback到我的pom。我在servlet的 doGet 方法中放置了一个日志记录。当运行servlet时,它抱怨它找不到任何绑定,因为logback jar没有被复制到Eclipse的tomcat实例中。我希望找到这里发布的罐子:

I'm trying to set up a basic hello world project using Eclipse Indigo and a Tomcat server. I created a dynamic project with a simple servlet. Tested the servlet and that worked fine. Then I enabled Maven support and added logback to my pom. I put a logging statement in the servlet's doGet method. When running the servlet, it complains it cannot find any bindings because the logback jars are not being copied into the Eclipse tomcat instance. I expected to find the jars published somewhere in here:

$ {workspace} \.metadata\.plugins\org.eclipse。 wst.server.core\tmp0\

如何让Eclipse正常使用WTP / Maven?

How do I get Eclipse to work with WTP/Maven properly? I also tried installing the m2e-wtp connector with no difference.

推荐答案

检查部署程序集(上下文)菜单项目),必须有映射 Maven依赖关系 - > WEB-INF / lib

Check Deployment Assembly (context menu on project), there must be mapping Maven Dependencies -> WEB-INF/lib.

这篇关于Eclipse WTP不会发布Maven依赖项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆