【发布时间】:2012-10-11 18:21:22
【问题描述】:
我曾经在本地 tomcat 服务器上部署我的 WAR,并且在 tomcat 的lib 文件夹中有一个 jackson-core.jar。现在,我已经切换到 maven 并且正在使用 jetty 插件。
除了我收到406 error - The server responded with 406 error (Not acceptable) 之外,一切正常。我知道错误即将到来,因为应用服务器(码头)中没有 jackson-core.jar。
问题:
我怎样才能像在独立的 tomcat 服务器上那样在嵌入式码头的 lib 文件夹中放置一个 jar。这可能吗?
我尝试了以下方法:
<configuration>
<scanIntervalSeconds>5</scanIntervalSeconds>
<webAppConfig>
<contextPath>/myapp</contextPath>
<extraClasspath>/Users/myuser/Downloads/jackson-core-2.1.0.jar</extraClasspath>
</webAppConfig>
</configuration>
【问题讨论】:
标签: tomcat maven embedded-jetty maven-jetty-plugin