/// <summary> /// Build a pipeline of HttpMessageHandlers. /// </summary> internal HttpMessageHandler BuildHandlerPipeline (bool chunkedMode) { var handler = new HttpClientHandler { CookieContainer = cookieStore, UseCookies = true }; Handler = new DefaultAuthHandler (handler, cookieStore, chunkedMode); var retryHandler = new TransientErrorRetryHandler(Handler); return retryHandler; }
/// <summary> /// Build a pipeline of HttpMessageHandlers. /// </summary> void BuildHandlerPipeline () { var handler = new HttpClientHandler { CookieContainer = cookieStore, UseDefaultCredentials = true, UseCookies = true, }; Handler = new DefaultAuthHandler (handler, cookieStore); }
/// <summary> /// Build a pipeline of HttpMessageHandlers. /// </summary> internal HttpMessageHandler BuildHandlerPipeline (CookieStore store, IRetryStrategy retryStrategy) { var handler = new WebRequestHandler { CookieContainer = store, UseCookies = true, ReadWriteTimeout = (int)SocketTimeout.TotalMilliseconds }; // For now, we are not using the client cert for identity verification, just to // satisfy Mono so it doesn't matter if the user doesn't choose it. //handler.ClientCertificates.Add(SSLGenerator.GetOrCreateClientCert()); if(handler.SupportsAutomaticDecompression) { handler.AutomaticDecompression = System.Net.DecompressionMethods.GZip | System.Net.DecompressionMethods.Deflate; } var authHandler = new DefaultAuthHandler (handler, store, SocketTimeout); if (retryStrategy == null) { return authHandler; } var retryHandler = new TransientErrorRetryHandler(authHandler, retryStrategy); return retryHandler; }
public CouchbaseLiteHttpClient(HttpClient client, DefaultAuthHandler authHandler) { _httpClient = client; _authHandler = authHandler; SetConcurrencyLimit(ReplicationOptions.DefaultMaxOpenHttpConnections); }
/// <summary> /// Build a pipeline of HttpMessageHandlers. /// </summary> internal HttpMessageHandler BuildHandlerPipeline (CookieStore store) { var handler = new HttpClientHandler { CookieContainer = store, UseCookies = true }; // For now, we are not using the client cert for identity verification, just to // satisfy Mono so it doesn't matter if the user doesn't choose it. //handler.ClientCertificates.Add(SSLGenerator.GetOrCreateClientCert()); if(handler.SupportsAutomaticDecompression) { handler.AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate; } Handler = new DefaultAuthHandler (handler, store); var retryHandler = new TransientErrorRetryHandler(Handler); return retryHandler; }
/// <summary> /// Build a pipeline of HttpMessageHandlers. /// </summary> internal HttpMessageHandler BuildHandlerPipeline (bool chunkedMode) { var handler = new HttpClientHandler { CookieContainer = cookieStore, UseCookies = true }; if (handler.SupportsAutomaticDecompression) { handler.AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate; } Handler = new DefaultAuthHandler (handler, cookieStore, chunkedMode); var retryHandler = new TransientErrorRetryHandler(Handler); return retryHandler; }