Maven的Jetty插件提示No Transaction manager found导致启动慢的解决方法
来源:互联网 发布:windows10 linux子系统 编辑:程序博客网 时间:2024/06/08 04:21
No Transaction manager found - if your webapp requires one, please configure one.
而且启动过程会暂停十几秒,在反复调试代码时很浪费时间,经过多天在网上搜索资料,终于找到了解决办法。
首先是pom.xml中关于插件的配置:
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>8.1.15.v20140411</version>
<configuration>
<stopKey>stop</stopKey>
<stopPort>9999</stopPort>
<scanIntervalSeconds>1</scanIntervalSeconds>
<contextXml>${project.basedir}/src/main/resources/jetty-context.xml</contextXml>
<webApp>
<contextPath>/</contextPath>
</webApp>
<connectors>
<connector implementation="org.eclipse.jetty.server.nio.SelectChannelConnector">
<port>80</port>
<maxIdleTime>60000</maxIdleTime>
</connector>
</connectors>
</configuration>
</plugin>
重要的是加上<contextXml>配置,我们要对jetty的服务器属性进行配置。本例中把配置文件放到了/src/main/resources中(如果你不希望打包时带上这个文件,可以放到/src/test/resources中,改下配置即可),文件名为:jetty-context.xml。接下来是配置文件:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://www.eclipse.org/jetty/configure.dtd">
<Configure class="org.eclipse.jetty.webapp.WebAppContext">
<Call name="setAttribute">
<Arg>org.eclipse.jetty.server.webapp.WebInfIncludeJarPattern</Arg>
<Arg>.*/.*jsp-api-[^/]\.jar$|./.*jsp-[^/]\.jar$|./.*taglibs[^/]*\.jar$</Arg>
</Call>
</Configure>
- maven的jetty插件提示No Transaction manager found导致启动慢的解决方法
- maven的jetty插件提示No Transaction manager found导致启动慢的解决方法
- Maven的Jetty插件提示No Transaction manager found导致启动慢的解决方法
- maven的jetty插件提示No Transaction manager found导致启动慢
- maven jetty插件报 No Transaction manager found
- Maven-Jetty的插件集成快速启动
- Maven下载插件很慢的解决方法
- maven web项目使用jetty插件启动的配置
- 360Replugin插件启动Activity慢导致ANR的问题
- maven jetty的eclipse 插件
- maven jetty 插件的使用
- Maven的jetty插件配置
- Cordova run提示No installed build tools found的解决方法
- Android SDK Manager下载慢的解决方法
- Android SDK Manager下载慢的解决方法
- Maven jetty debug 提示source not found
- IE启动慢的解决方法
- Office2010启动慢的解决方法
- HDOJ1023(卡特兰数+大数乘除法)
- 2017,晚来的第一篇
- 坚持#第193天~合格的云计算运维工程师
- 移动端常用的meta标签
- log4j配置详解
- Maven的Jetty插件提示No Transaction manager found导致启动慢的解决方法
- 单词
- camera基本知识
- 调整运动
- com.netflix.discovery.DiscoveryClient
- 为 hexo NexT 添加 Gitment 评论插件
- 关于this、arguments、caller、callee、prototype、__proto__、length
- 获取浏览器url地址请求参数--requestParam.js
- 第一个只出现一次的字符