Closed StevenBlair123 closed 4 years ago
Inside SubscriptionService, we have the folloiwng code:
using (var httpClient = new HttpClient())
This is pretty inefficient, and we should look at building a HttpClient per endpoint (at least) to benefit from conenction pooling.
My guess is, this needs to live somewhere along with each Subscription.
Need to work out the best way to go about this.
A new httpClient specific to the Subscription is now available in the Subscription (Domain), so this should be a quick change.
Inside SubscriptionService, we have the folloiwng code:
using (var httpClient = new HttpClient())
This is pretty inefficient, and we should look at building a HttpClient per endpoint (at least) to benefit from conenction pooling.
My guess is, this needs to live somewhere along with each Subscription.
Need to work out the best way to go about this.