问题 I've learned that in spring, i can autowire/inject into Map<String, SomeBeanInterface> by configured name like below: public interface DummyInterface{ } @Component("impl1") public class Impl1 implement DummyInterface{ } @Component("impl2") public class Impl2 implement DummyInterface{ } public class SomeUsage{ @Autowired private Map<String, DummyInterface> mapping; // ... } and retrieve the Component by string as key like: SomeUsage use = new SomeUsage(); DummyInterface dummy = use.getMapping(