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

Allow dev environments to auto-enable dev-centric features in "slim" host builder #46096

Open
DamianEdwards opened this issue Jan 13, 2023 · 3 comments
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Milestone

Comments

@DamianEdwards
Copy link
Member

The new "slim" host builder API (#32485) removes a number of default features that exist to make the development time better. It would be great to allow for the development environment (e.g. Visual Studio, dotnet run, dotnet watch, etc.) to be able to re-enable these features when launching the application during the development inner-loop experience so that even when using the slim builder these dev-centric features are still enabled when launched from the developer environment.

The features in question:

  • User secrets configuration provider
  • Debug logger
  • IHostingStartup (enables things like the browser refresh middleware to be injected so the browser can be refreshed on code-change, aka Hot Reload)

This could be achieved by adding a new runtime switch that the slim host builder API would check and if enabled would add these features to the host builder. The switch can be set by the launching environment by passing a build property when building the project, e.g. -p:EnableWebApplicationBuilderDevelopmentFeatures=true (super bad name but you get the idea).

@DamianEdwards
Copy link
Member Author

@eerhardt @davidfowl

@javiercn
Copy link
Member

@DamianEdwards It would be great if we can do this from libraries and MSBuild. In other words, compliment this with the ability for libraries to bring in the development features without additional gestures.

There is another case where we use this:

  • SPAProxy middleware, which uses hosting startup.

It would also be good to be able to plug-in Blazor Debugging support in hosted projects in a similar way, rather than have it be part of the pipeline.

@ghost
Copy link

ghost commented Jan 19, 2023

Thanks for contacting us.

We're moving this issue to the .NET 8 Planning milestone for future evaluation / consideration. We would like to keep this around to collect more feedback, which can help us with prioritizing this work. We will re-evaluate this issue, during our next planning meeting(s).
If we later determine, that the issue has no community involvement, or it's very rare and low-impact issue, we will close it - so that the team can focus on more important and high impact issues.
To learn more about what to expect next and how this issue will be handled you can read more about our triage process here.

@amcasey amcasey added area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Aug 24, 2023
@dotnet-policy-service dotnet-policy-service bot added the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Feb 6, 2024
@wtgodbe wtgodbe removed the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Feb 6, 2024
@dotnet-policy-service dotnet-policy-service bot added the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Feb 6, 2024
@wtgodbe wtgodbe removed the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Feb 13, 2024
@dotnet dotnet deleted a comment from dotnet-policy-service bot Feb 13, 2024
@dotnet dotnet deleted a comment from dotnet-policy-service bot Feb 13, 2024
@amcasey amcasey modified the milestones: .NET 8 Planning, Backlog Feb 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

No branches or pull requests

5 participants