Why I can't reuse WebClient to make the same request twice?
问题 So the code: const long testCount = 2; const string jsonInput = "{\"blockId\":\"1\",\"userId\":\"{7c596b41-0dc3-45df-9b4c-08840f1da780}\",\"sessionId\":\"{46cd1b39-5d0a-440a-9650-ae4297b7e2e9}\"}"; Stopwatch watch = Stopwatch.StartNew(); using (var client = new WebClient()) { client.Headers["Content-type"] = "application/json"; client.Encoding = Encoding.UTF8; for (int i = 0; i < testCount; i++) { var response = client.UploadString("http://localhost:8080/BlocksOptimizationServices