简体   繁体   English

为什么eclipse不能将所有jar文件移动到服务器lib文件夹?

[英]why eclipse does not move all jar files to server lib folder?

I have mvn web application project. 我有MVN Web应用程序项目。 I run 我跑

mvn clean install
mvn eclipse:eclipse

in target{project-name}\\WEB-INF\\lib dictonary, here is all jar files (amount of all jar is 77), that I have declared in pom.xml. target {项目名称} \\ WEB-INF \\ lib字典中,这是我在pom.xml中声明的所有jar文件(所有jar的数量为77)。

  1. I have created new server in eclipse . 我在eclipse中创建了新服务器。
  2. add priject to server. 将主题添加到服务器。

when I open servers project lib dictonary path\\apache-tomcat-8.0.14\\webapps{project-name}\\WEB-INF\\lib I found all jar files, except one (amount of all jar is 76). 当我打开服务器项目lib字典路径\\ apache-tomcat-8.0.14 \\ webapps {project-name} \\ WEB-INF \\ lib时,我找到了所有jar文件,除了一个(所有jar的数量为76)。

why this happens? 为什么会这样?

I do not have this jar file: 我没有这个jar文件:

<dependency>
      <groupId>org.lazyluke</groupId>
      <artifactId>log4jdbc-remix</artifactId>
      <version>0.2.7</version>
</dependency>

The same happens , for example, when I add another jars in pom.xml. 例如,当我在pom.xml中添加另一个jar时,也会发生同样的情况。 I do not understand why eclipse does not copy all the jars... 我不明白为什么eclipse不能复制所有罐子...

Eclipse version: Luna Tomcat version: 8.0.14 Eclipse版本:Luna Tomcat版本:8.0.14

There are issues with eclipse-maven synchronization. eclipse-maven同步存在问题。 If pom is changed this doesn't get synchronized with webapps already deployed on the Tomcat. 如果更改pom,则不会与已在Tomcat上部署的Web应用程序同步。 So you need to do 所以你需要做

Tomcat>Clean...

This will do the sync. 这将进行同步。 Also make sure maven dependencies are added in 还要确保在其中添加了Maven依赖项

Project>Properties>Deployment Assesmbly

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM