您的位置:首页 > 运维架构 > Tomcat

tomcat部署多工程Singleton bean creation not allowed while the singletons of this factory are in destructi

2017-11-09 20:16 701 查看
场景:同一个tomcat下部署多个java工程。

问题现象: 启动tomcat时报异常Singleton bean creation not allowed while the singletons of this factory are in destruction

问题原因:不同的工程分别创建了同一个单例。

处理方案:1、在应用的web.xml文件中,配置不同的webAppRootKey,<param-value>值可以自定义,只要相同tomcat下的各个工程保持不同即可。

<context-param>  

  <param-name>webAppRootKey</param-name>  

  <param-value>web.sample.root</param-value>  

</context-param>  
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐