@@ -232,7 +232,6 @@ private void CreateHttpClient()
232
232
}
233
233
234
234
httpClientHandler . Proxy = this . Proxy ;
235
- // httpClientHandler.MaxConnectionsPerServer = 2000;
236
235
237
236
this . client = new HttpClient ( httpClientHandler ) ;
238
237
string userAgentString = string . Format ( CultureInfo . InvariantCulture , UserAgentHeaderTemplate , ResourceUtilities . AssemblyVersion , ResourceUtilities . PlatformFamily ) ;
@@ -249,7 +248,7 @@ private void CreateHttpClient()
249
248
250
249
private async Task < HttpResponseInfo > MakeHttpRequest ( HttpRequestInfo requestInfo )
251
250
{
252
- SendingRemoteHttpRequestEventArgs eventArgs = new SendingRemoteHttpRequestEventArgs ( null , requestInfo . RequestBody ) ;
251
+ SendingRemoteHttpRequestEventArgs eventArgs = new SendingRemoteHttpRequestEventArgs ( requestInfo . HttpMethod , requestInfo . FullUri . ToString ( ) , requestInfo . RequestBody ) ;
253
252
this . OnSendingRemoteHttpRequest ( eventArgs ) ;
254
253
255
254
HttpMethod method = new HttpMethod ( requestInfo . HttpMethod ) ;
@@ -301,29 +300,6 @@ private Response CreateResponse(HttpResponseInfo responseInfo)
301
300
response . Value = body ;
302
301
}
303
302
304
- //if (this.CommandInfoRepository.SpecificationLevel < 1 && (responseInfo.StatusCode < HttpStatusCode.OK || responseInfo.StatusCode >= HttpStatusCode.BadRequest))
305
- //{
306
- // if (responseInfo.StatusCode >= HttpStatusCode.BadRequest && responseInfo.StatusCode < HttpStatusCode.InternalServerError)
307
- // {
308
- // response.Status = WebDriverResult.UnhandledError;
309
- // }
310
- // else if (responseInfo.StatusCode >= HttpStatusCode.InternalServerError)
311
- // {
312
- // if (responseInfo.StatusCode == HttpStatusCode.NotImplemented)
313
- // {
314
- // response.Status = WebDriverResult.UnknownCommand;
315
- // }
316
- // else if (response.Status == WebDriverResult.Success)
317
- // {
318
- // response.Status = WebDriverResult.UnhandledError;
319
- // }
320
- // }
321
- // else
322
- // {
323
- // response.Status = WebDriverResult.UnhandledError;
324
- // }
325
- //}
326
-
327
303
if ( response . Value is string )
328
304
{
329
305
response . Value = ( ( string ) response . Value ) . Replace ( "\r \n " , "\n " ) . Replace ( "\n " , Environment . NewLine ) ;
0 commit comments