I think I can add a little more information here:
I'm not sure that the name of the method is critical so much as the @Bean annotation is
In this example, no, it doesn't matter since there's an explicit name in the @Bean annotation.
Naming does matter with this, however, as beans always have names, even if they're not declared manually:
In this case, the bean's name is the method name. With that, it's generally just simpler to just let Spring do the naming do the work for you via method name. So an equivalent to the previous example is:
As for the behavior in question, I believe this is what happens, but can't find the specific documentation. I recognize that's basically what is being asked here, but I'm struggling to find explicit documentation on what the load order is here.
1. Spring scans for components
2. Finds a @Component and @Configuration - loads beans from @Configuration
3. Sees there is already a component named "businessBean" so does not load this bean. This would essentially be a bean override.
That makes sense to me, at least, knowing what I know about Spring's general behavior and having written code with beans intended to be overridden by name. Basically, the first bean with a given name wins.
There was a general discussion about this behavior and that it was not desired behavior here:
https://github.com/spring-projects/spring-boot/issues/13609
As of Spring Boot 2.1.0, overriding a bean by name requires setting a property, so on Spring Boot 2.1.0 at least, I would expect this to cause a startup failure.