I am using NSwag to create typed http clients with interfaces and registering them with DI using AddHttpClient() and injecting them where they need to be used in calling APIs.
I read about some limitations of the httpclient class such as socket exhaustion & not detecting dns changes and the recommendation to use httpClientFactory and its CreateClient method to create httpclients to alleviate these limitations.
I haven't used the httpClientFactory in a new app that I started working on. It's using .NET 6 and my question is.. Is httpClientFactory still a recommended way to use explicitly or is it used implicitly in DI because of the use of AddHttpClient() and I don't have to worry about those limitations? I didn't see a clear direction on how to use typed clients, or http clients in general, and whether .NET 6 has introduced improvements in this area.