-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Description
Library name and version
System.ClientModel 1.10.0
Query/Question
Every time I read about the features of System.ClientModel, I get more and more confused.
I've been using raw HttpClient (with IHttpClientFactory for a long time). More recently, I've started using the kiota libraries along with openapi specs for as many APIs as we can. kiota comes with its own share of abstractions and "pipeline"-like extensions (via DelegatingHandlers) for various things. Then, even more recently, we started leveraging the Microsoft.Extensions.ServiceDiscovery library (initially part of Aspire) so that we could have a consistent means of specifying service urls in configuration and easily configure them, as well as to integrate with Aspire itself which relies heavily on the pattern.
Then comes System.ClientModel and throws a MASSIVE wrench at everything we've been using basically...
- It (very recently) defined its own DI+configuration experience, using a completely new configuration section with properties that do not at all match the previous
Servicessection defined by service discovery. This now means we have 2 distinct (and conflicting) mechanisms to represent our services in configuration - It declares various abstractions around authentication, transport, etc that are very similar to some of the abstractions defined in
kiota, which makes everything confusing and redundant, especially if you want to use both - It invents its own completely custom "retry" thing, when we already have extensive Polly integration with
HttpClient - It comes up with this crazy "configuration extension" thing for declaring "reusable variables" in config, instead of pushing the
Extensions.Configurationframework to support that natively or promoting something like Workleap.Extensions.Configuration.Substitution or expanding upon it - It is called
System.ClientModel(super generic), yet it sits in the Azure SDK repo (WTH) and has "cloud" mentioned all over its documentation even though the abstractions themselves seem to be completely generic
I just want to understand what Microsoft is doing here. You have 3 teams:
- Azure SDK team doing its own thing
kiotateam doing its own thing- dotnet/aspnetcore/extensions team doing its own thing
How are we supposed to reconcile all this mess? Why don't you talk with each other to come up with a common set of abstractions that work together for all purposes instead of each one creating their own thing in an incompatible manner?
Maybe I'm just missing something incredibly obvious here, but I'm frustrated right now: there seems to be an opportunity to unify and simplify things around service calling/configuration here, and from my perspective your teams are dropping the ball and making an absolute mess of it.
What is the purpose of this library exactly and why is it so custom compared to other abstractions in the ecosystem such as kiota and service discovery?
@CarnaViire
@davidfowl
@baywet (I know you are not in the kiota team anymore but you must have the most context here)
Thoughts?
Environment
N/A