Reputation: 69
I'm using HttpClient to make batches of request to a number of servers. There may be a number of batches in progress at any given time.
I use one Httpclient per batch which will all go to the same server. So if I have 3 jobs in flight to 3 servers I use one HttpClient per server.
A job makes 100 to 2000 requests to the server endpoint and 3 to 5 request asysnc.
The server endpoint config is beyond my control.
What I want to know what are the best settings to ensure success and performance?
So for example I already have a ServicePointManager.ServerCertificateValidationCallback that always returns true. I set ServicePointManager.DefaultConnectionLimit to 100
I'm wondering what settings I need for things like ServicePointManager.SecurityProtocol ServicePointManager.SetTcpKeepAlive and anything else?
to always ensure success in particular around their HTTP/HTTPS setup and what tweaks might help with performance?
Upvotes: 3
Views: 727