Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding IStartupFilter support #1675

Merged
merged 1 commit into from
Apr 19, 2018

Conversation

jrestall
Copy link
Contributor

The middleware pipeline for a tenant can now be configured using IStartupFilter, this allows libraries that use this interface as part of their initialisation to work e.g. Microsoft.AspNetCore.Mvc.Versioning, Microsoft.AspNetCore.MiddlewareAnalysis and many others.

See this comment for more info: #839 (comment)

I did investigate the two issues concerning me, the config pipeline ordering and the AutoRequestServicesStartupFilter. Both are now resolved:

  • I've changed the code so that the startup filters configure the pipeline in the correct order.
  • I've confirmed that AutoRequestServicesStartupFilter isn't an issue. We set the HttpContext.RequestServices property first ensuring the RequestServicesContainerMiddleware.cs doesn't set the service provider again since it checks if a provider is already set.

The middleware pipeline for a tenant can now be configured using IStartupFilter, this allows libraries that use this interface as part of their initialisation to work e.g. Microsoft.AspNetCore.Mvc.Versioning.
@jrestall jrestall mentioned this pull request Apr 15, 2018
10 tasks
@sebastienros sebastienros merged commit fa4ac67 into OrchardCMS:dev Apr 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants