Skip to content

API Proposal: Expose Host.ConfigureDefaults #36003

Closed

Description

@davidfowl

This would allow callers to provide the IHostBuilder instance without having to copy all the logic to setup defaults.

Activity

  1. analogrelay commented on Jan 24, 2020

    @analogrelay
    Contributor

    Do you have more specific details on the proposal? This is pretty low on info/details.

  2. analogrelay commented on Jan 24, 2020

    @analogrelay
    Contributor

    :trollface:

  3. davidfowl commented on Jan 31, 2020

    @davidfowl
    MemberAuthor

    I had to copy the defaults because I wanted to use a different IHostBuilder implementation https://github.com/davidfowl/FeatherHttp/blob/ee5e2a8a701b73b1e57c5d4df5672fda63366779/src/FeatherHttp/WebApplication.cs#L221.

    The request is simple, I’d rather not copy this logic 😬

  4. Dotnet-GitSync-Bot commented on May 7, 2020

    @Dotnet-GitSync-Bot
    Collaborator

    I couldn't figure out the best area label to add to this issue. Please help me learn by adding exactly one area label.

  5. added
    untriaged
    on May 7, 2020
  6. added this to the Future milestone on May 7, 2020
  7. removed
    untriaged
    on Jun 22, 2020
  8. added
    api-suggestion
    on Oct 1, 2020
  9. maryamariyan commented on Oct 22, 2020

    @maryamariyan
    Contributor

    API Proposal Summary:

    The ask is to move the IHostBuilder instantiation below out of the new API, so other callers can provide their own IHostBuilder to CreateDefaultBuilder

    var builder = new HostBuilder();

    namespace Microsoft.Extensions.Hosting
    {
        public static partial class Host
        {
            public static Microsoft.Extensions.Hosting.IHostBuilder CreateDefaultBuilder() { throw null; }
            public static Microsoft.Extensions.Hosting.IHostBuilder CreateDefaultBuilder(string[] args) { throw null; }
    +       public static Microsoft.Extensions.Hosting.IHostBuilder CreateDefaultBuilder(IHostBuilder builder, string[] args) { throw null; }
        }
    }
  10. added
    api-ready-for-review
    and removed
    api-suggestion
    on Oct 22, 2020
  11. removed
    api-ready-for-review
    on Jan 21, 2021
  12. 2 remaining items

  13. davidfowl commented on Jan 21, 2021

    @davidfowl
    MemberAuthor

    Nice!

  14. self-assigned this
    on Mar 25, 2021
  15. modified the milestones: Future, 6.0.0 on Mar 25, 2021
  16. added
    help wanted
    on Mar 29, 2021
  17. IEvangelist commented on Mar 30, 2021

    @IEvangelist
    Member

    If you're okay with it @maryamariyan and @davidfowl, I'd love to work on this?

  18. davidfowl commented on Mar 30, 2021

    @davidfowl
    MemberAuthor

    Do it!

  19. added a commit that references this issue on Mar 30, 2021
    a4afaae
  20. ghost added
    in-pr
    on Mar 30, 2021
  21. added a commit that references this issue on Mar 31, 2021
    082af35
  22. ghost removed
    in-pr
    on Mar 31, 2021
  23. ghost locked as resolved and limited conversation to collaborators on Apr 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

api-approvedarea-Extensions-Hostinghelp wanted

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions