现象:eclipse里面连接activemq是正常的,打包到外面的tomcat7运行,连接上activemq后马上就掉线了
原因:tomcat7的异步特性没有生效
办法:
1.让eclipse使用tomcat7插件:
2.所有相关的Servlet及Filter加上<async-supported>true</async-supported>
参考:
(转)使用Servlet3.0新特性asyncSupported=true时抛异常java.lang.IllegalStateException: Not support...
Tomcat7使用ActiveMQ AjaxServlet时,发生Not supported. exception
Maven 集成Tomcat插件