tomcat启动报错,找不到相应的 queue,从而引发内存泄漏
tomcat启动报错,无法创建 bean listenerStatusChangeDealHandler, no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost
从启动日志来看,有时候仅会看到内存泄漏。而没有与queue相关的日志,非常easy走错方向。
依照 http://blog.csdn.net/wangjunjun2008/article/details/23375501 的方法能够看到具体日志。从而确定报错原因
tomcat启动报错,无法创建 bean listenerStatusChangeDealHandler, no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost
Jun 5, 2014 1:39:42 PM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.context.ApplicationContextException: Failed to start bean 'listenerStatusChangeDealHandler';
nested exception is org.springframework.amqp.AmqpIllegalStateException: Fatal exception on listener startup
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:169)
...
Caused by: org.springframework.amqp.AmqpIllegalStateException: Fatal exception on listener startup
at org.springframework.amqp.rabbit.listener.SimpleMessageListenerContainer.doStart(SimpleMessageListenerContainer.java:339)
at org.springframework.amqp.rabbit.listener.AbstractMessageListenerContainer.start(AbstractMessageListenerContainer.java:363)
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:166)
... 33 more
Caused by: org.springframework.amqp.rabbit.listener.FatalListenerStartupException: Cannot prepare queue for listener.
Either the queue doesn't exist or the broker will not allow us to use it.
at org.springframework.amqp.rabbit.listener.BlockingQueueConsumer.start(BlockingQueueConsumer.java:228)
at org.springframework.amqp.rabbit.listener.SimpleMessageListenerContainer$AsyncMessageProcessingConsumer.run(SimpleMessageListenerContainer.java:524)
at java.lang.Thread.run(Thread.java:662)
Caused by: com.rabbitmq.client.ShutdownSignalException: channel error; reason: {#method<channel.close>(reply-code=404, reply-text=NOT_FOUND - no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost '/', class-id=50, method-id=10), null, ""}
at com.rabbitmq.utility.ValueOrException.getValue(ValueOrException.java:67)
at com.rabbitmq.utility.BlockingValueOrException.uninterruptibleGetValue(BlockingValueOrException.java:33)
at com.rabbitmq.client.impl.AMQChannel$BlockingRpcContinuation.getReply(AMQChannel.java:343)
at com.rabbitmq.client.impl.AMQChannel.privateRpc(AMQChannel.java:216)
at com.rabbitmq.client.impl.AMQChannel.exnWrappingRpc(AMQChannel.java:118)
... 11 more
Caused by: com.rabbitmq.client.ShutdownSignalException: channel error; reason: {#method<channel.close>(reply-code=404, reply-text=NOT_FOUND - no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost '/', class-id=50, method-id=10), null, ""}
at com.rabbitmq.client.impl.ChannelN.asyncShutdown(ChannelN.java:454)
at com.rabbitmq.client.impl.ChannelN.processAsync(ChannelN.java:294)
at com.rabbitmq.client.impl.AMQChannel.handleCompleteInboundCommand(AMQChannel.java:144)
at com.rabbitmq.client.impl.AMQChannel.handleFrame(AMQChannel.java:91)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:526)
Jun 5, 2014 1:39:42 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Jun 5, 2014 1:39:42 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/TravelHubPkgStock] startup failed due to previous errors
Jun 5, 2014 1:39:42 PM org.apache.catalina.core.ApplicationContext log
INFO: Closing Spring root WebApplicationContext
Jun 5, 2014 1:39:42 PM org.apache.catalina.loader.WebappClassLoader clearReferencesJdbc
SEVERE: The web application [/TravelHubPkgStock] registered the JDBC driver [oracle.jdbc.driver.OracleDriver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
Jun 5, 2014 1:39:42 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/TravelHubPkgStock] appears to have started a thread named [Thread-2] but has failed to stop it. This is very likely to create a memory leak.
Jun 5, 2014 1:39:42 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/TravelHubPkgStock] appears to have started a thread named [Thread-3] but has failed to stop it. This is very likely to create a memory leak.
Jun 5, 2014 1:39:47 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
Jun 5, 2014 1:39:48 PM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:9090
Jun 5, 2014 1:39:48 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/121 config=null
Jun 5, 2014 1:39:48 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 324602 ms
经过排查和測试,发现项目中使用rabbitmq服务,而rabbitmq于昨天被重装了,从而里面的队列所有没有了,导致项目启动时初始化bean时候报错。
有趣的是,之前rabbitmq停止服务时。该项目启动正常。而rabbitmq服务提供服务,且某一指定队列不存在时。项目却无法正常启动,
由此可见。代码的健壮性有待改进哪。
tomcat启动报错,找不到相应的 queue,从而引发内存泄漏的更多相关文章
- 转!java web项目 build path 导入jar包,tomcat启动报错 找不到该类
在eclipse集成tomcat开发java web项目时,引入的外部jar包,编译通过,但启动tomcat运行web时提示找不到jar包内的类,需要作如下配置,将jar包在部署到集成的tomcat环 ...
- tomcat启动报错
[toc]启动错误 does not exist or is not a readable directory 问题:tomcat启动报错:does not exist or is not a rea ...
- Tomcat启动报错:StandardServer.await: create[8005] java.net.BindException: Cannot assign requested address
Tomcat启动报错:StandardServer.await: create[8005] java.net.BindException: Cannot assign requested addres ...
- Tomcat启动报错org.springframework.web.context.ContextLoaderListener类配置错误——SHH框架
SHH框架工程,Tomcat启动报错org.springframework.web.context.ContextLoaderListener类配置错误 1.查看配置文件web.xml中是否配置.or ...
- tomcat启动报错Several ports (8080, 8009) required by Tomcat v6.0
tomcat启动报错 如下图: 问题:8080.8009端口已经被占用. 解决办法: 1.在命令提示符下,输入netstat -aon | findstr 8080 2.继续输入taskkill -F ...
- [转]tomcat启动报错too low setting for -Xss
tomcat启动报错too low setting for -Xss 网上给的答案都是调整Xss参数,其实不是正确的做法, -Xss:每个线程的Stack大小,“-Xss 15120” 这使得tomc ...
- tomcat启动报错 ERROR o.a.catalina.session.StandardManager 182 - Exception loading sessions from persiste
系统:centos6.5 x86_64 jdk: 1.8.0_102 tomcat:8.0.37 tomcat 启动报错: ERROR o.a.catalina.session.StandardMan ...
- Tomcat启动报错:[The configuration may be corrupt or incomplete]的解决方案
1,场景说明: 偶然碰见Tomcat启动报错,此时并没有Add任何Web项目: Could not load the Tomcat server configuration at /Servers/T ...
- tomcat启动报错:Injection of autowired dependencies failed
tomcat启动报错:Injectjion of autowired dependencies failed 环境: 操作系统:centos6.5 tomcat: 7.0.52 jdk:openjdk ...
随机推荐
- 让你的chrome开发工具console支持jquery
首先执行以下代码: ;(function(d,s){d.body.appendChild(s=d.createElement('script')).src='http://code.jquery.co ...
- request.getScheme() 取到https正确的协议(转载)
最近在做一个项目, 架构上使用了 Nginx +tomcat 集群, 且nginx下配置了SSL,tomcat no SSL,项目使用https协议 但是,明明是https url请求,发现 log里 ...
- Educational Codeforces Round 11 A. Co-prime Array 水题
A. Co-prime Array 题目连接: http://www.codeforces.com/contest/660/problem/A Description You are given an ...
- hdu 4802 GPA 水题
GPA Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=4802 Des ...
- linux基础命令学习 (十)Vi
1.vi的基本概念 基本上vi可以分为三种状态,分别是命令模式(command mode).插入模式(Insert mode)和底行模式(last line mode),各模式的功能区分如下: ...
- MYSQL学习笔记 (四)GROUP BY与HAVING用法
注意:select 后的字段,必须要么包含在group by中,要么包含在having 后的聚合函数里. 1. GROUP BY 是分组查询, 一般 GROUP BY 是和聚合函数配合使用 group ...
- java同步ldap实例
1.准备过程 1.1 在windows server 2008 R2操作系统下搭建AD域,不懂得看链接地址:http://99532720.blog.51cto.com/2194488/696611 ...
- Ext文本输入框:Ext.form.TextField属性汇总(转) (
本章介绍Ext.form.TextField组件的基本用法: <form id="form1" runat="server"> <div ...
- django 获取 POST 请求值的几种方法(转)
转载请注明出处:http://hi.baidu.com/leejun_2005/blog/item/9a37a22238f35c5bac34de54.html from:http://stackove ...
- One switched-capacitor IC simultaneously inverts, doubles, and halves the input voltage.