admin管理员组文章数量:1417434
I'm using FlightRecorderApplicationStartup to gain insight in my spring application startup.
I find numerous spring.beans.instantiate events tagged like this:
beanName=.springframework.security.authenticationManager,exception=class .springframework.beans.factory.BeanCurrentlyInCreationException, message=Error creating bean with name '.springframework.security.authenticationManager': Requested bean is currently in creation: Is there an unresolvable circular reference or an asynchronous initialization dependency?, beanName=.springframework.security.authenticationManager,exception=class .springframework.beans.factory.BeanCurrentlyInCreationException,message=Error creating bean with name '.springframework.security.authenticationManager': Requested bean is currently in creation: Is there an unresolvable circular reference or an asynchronous initialization dependency?
Typically hundreds of such events all have the same parentId (which is just another spring.beans.instantiate of one of my beans).
I would like to learn how to understand this. How can spring log this problem and still work around it?
It looks like spring fails to create this bean many times, while still proceeding (my application starts fine).
I assume this is not the ideal flow of events: what can i do to investigate?
If this is an indication of the fact that i would have circular bean dependencies, how can i identify the beans involved in a circular dependency chain? I know adding @Lazy at specific points is a solution, but i don't know how to find the cycles.
Using
<.springframework.version>6.2.2</.springframework.version>
<.springframework.security.version>6.4.2</.springframework.security.version>
本文标签:
版权声明:本文标题:Error creating bean with name 'org.springframework.security.authenticationManager': Requested bean is currently 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745270269a2650848.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论