You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 4, 2021. It is now read-only.
I'm trying to figure out how I can benefit from the new .netcore HttpFactory dependency injection to register the VSS clients in my startup class like so:
publicasync Task Method([FromServices]WorkItemTrackingHttpClientclient,intid){varworkitem=await client.GetWorkItemAsync(id);//do something with the workitem...}
Currently, I'm facing this exception when doing the above:
InvalidOperationException: A suitable constructor for type 'Microsoft.TeamFoundation.WorkItemTracking.WebApi.WorkItemTrackingHttpClient' could not be located. Ensure the type is concrete and services are registered for all parameters of a public constructor.
Has any one managed to do it?
Would be good to have a sample for this.
Thanks,
Yoni
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello!
I'm trying to figure out how I can benefit from the new .netcore HttpFactory dependency injection to register the VSS clients in my startup class like so:
and then in a service/controller method:
Currently, I'm facing this exception when doing the above:
InvalidOperationException: A suitable constructor for type 'Microsoft.TeamFoundation.WorkItemTracking.WebApi.WorkItemTrackingHttpClient' could not be located. Ensure the type is concrete and services are registered for all parameters of a public constructor.
Has any one managed to do it?
Would be good to have a sample for this.
Thanks,
Yoni
The text was updated successfully, but these errors were encountered: