When I register multiple services to the DI container with the same interface and then request an IEnumerable
, do the container guarantee that t
Yes they execute in order, read more: https://docs.microsoft.com/en-us/aspnet/core/fundamentals/dependency-injection?view=aspnetcore-3.1
EDIT: More specific link: https://docs.microsoft.com/en-us/aspnet/core/fundamentals/startup?view=aspnetcore-3.1#extend-startup-with-startup-filters
Thanks to @Sai Puli
Yes it does. The order is based on registration order and is guaranteed