Regarding multiple beans of the same type like parrot1, parrot2, parrot3 in your example. How can I retrieve them all from the context as a List of parrots? Would I define a @Bean method returning List? or what would be the best practice in this case?
@laurspilca3 ай бұрын
Hey. Thanks for the question. Normally you can use the context.getBeansOfType() method for that. However, I never really had a real world scenario where I have used this.