We have a few places across the codebase where we are accidentally using lite configuration mode with @Bean methods on a class that is not annotated with @Configuration. To avoid unexpected behaviour and to pave the way for #9068, we should make sure that we're only using @Bean on @Configuration classes.