How to register multiple implementations of the same interface in Asp.Net Core?
I have services that are derived from same interface public interface IService { } public class ServiceA : IService { } public class ServiceB : IService { } public class ServiceC : IService { } Typically other IOC containers like Unity allow you to register concrete implementations by some Key that distinguishes them. In Asp.Net Core how do I register these services and resolve it at runtime based on some key? I don't see any of the Add Service method takes key or name parameter that typically used to distinguish the concrete implementation. public void ConfigureServices(IServiceCollection