Injection of beans into BeanPostProcessor causes Spring warnings
Fixed
Description fields
Basics
Logistics
Basics
Logistics
Description
Not sure how fixable this is, but there’s a pattern in the metadata resolver service where we inject various NodeProcessor beans via auto-wiring into a special BeanPostProcessor that ensures a NodeProcessing filter is attached to any metadata resolvers.
Spring 6.1 cranked an older log message on INFO up to WARN to basically say “hey, clearly we can’t post process these beans with your post processor because we have to inject them into it”.
It’s obvious why they’re saying it, but it’s deliberate here so I don’t know if it can be fixed short of not using that trick. But I didn’t come up with any alternate ways of ensuring the node processors get attached while allowing deployer override. The idea was that we’d auto-wire in the ones we need but deployers could prevent it if they wanted, not that anybody has.
I suppose maybe we could do something in the MetadataResolver Spring parsers to do this for us instead of doing it from the outside, but it’s unfortunate as this trick has been working really well.
Not sure how fixable this is, but there’s a pattern in the metadata resolver service where we inject various NodeProcessor beans via auto-wiring into a special BeanPostProcessor that ensures a NodeProcessing filter is attached to any metadata resolvers.
Spring 6.1 cranked an older log message on INFO up to WARN to basically say “hey, clearly we can’t post process these beans with your post processor because we have to inject them into it”.
It’s obvious why they’re saying it, but it’s deliberate here so I don’t know if it can be fixed short of not using that trick. But I didn’t come up with any alternate ways of ensuring the node processors get attached while allowing deployer override. The idea was that we’d auto-wire in the ones we need but deployers could prevent it if they wanted, not that anybody has.
I suppose maybe we could do something in the MetadataResolver Spring parsers to do this for us instead of doing it from the outside, but it’s unfortunate as this trick has been working really well.