tomcat循环调用Bug

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/zfzfzz/article/details/88837819

tomcat循环调用:

需要将循环的server拆出来 ,本例将ModuleContentService.Java中引用的AsyncService.Java移出,成功解决。

需要注意的是,这次bug仅出现在线上环境部署中,本机运行同样的代码没有出现此bug。

2019-03-27 09:59:18,173 ERROR [localhost-startStop-1] ContextLoader.initWebApplicationContext(350) - Context initialization failed
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'roleService': Unsatisfied dependency expressed through field 'userCenterService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'userCenterService': Unsatisfied dependency expressed through field 'operateService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'operateService': Unsatisfied dependency expressed through field 'plateService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating beanwith name 'plateService': Unsatisfied dependency expressed through field 'moduleService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'moduleService': Unsatisfied dependency expressed through field 'moduleContentService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'moduleContentService': Unsatisfied dependency expressed through field 'asyncService'; nested exception is org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'asyncService': Bean with name 'asyncService' has been injected intoother beans [channelService] in its raw version as part of a circular reference, but has eventually been wrapped. This means that said other beans do not use the final version of the bean. This is often the result of over-eager type matching - consider using 'getBeanNamesOfType' with the 'allowEagerInit' flag turned off, for example.

猜你喜欢

转载自blog.csdn.net/zfzfzz/article/details/88837819