spring-shell
spring-shell copied to clipboard
CommandRegistration beans should be "optional"
trafficstars
As with #380 command registrations more fully dynamic and user can just define CommandRegistration as a bean it might be beneficial to allow user to define when to register those beans.
Use case for not to automatically register CommandRegistration as a bean might be that you still want those as a bean in an application context(possibly handling registration manually). Maybe some annotations to disable registrations or settings in a autoconfiguration or something similar.
Hi @jvalkeal , I m wondering what means the optional? If user register CommandRegistration in a @Bean way, they already have the @ConfitionalOnXXX to control those beans.