Commit 56fb7aa5 authored by justcoding121's avatar justcoding121

enable connection pool by default

parent 32c750fb
......@@ -23,7 +23,7 @@ namespace Titanium.Web.Proxy.Examples.Basic
public ProxyTestController()
{
proxyServer = new ProxyServer();
proxyServer.EnableConnectionPool = true;
//proxyServer.EnableConnectionPool = false;
// generate root certificate without storing it in file system
//proxyServer.CertificateManager.CreateRootCertificate(false);
......
......@@ -155,10 +155,10 @@ namespace Titanium.Web.Proxy
public bool Enable100ContinueBehaviour { get; set; }
/// <summary>
/// Should we enable experimental Tcp server connection pool?
/// Defaults to false.
/// Should we enable server connection pool?
/// Defaults to true.
/// </summary>
public bool EnableConnectionPool { get; set; }
public bool EnableConnectionPool { get; set; } = true;
/// <summary>
/// Buffer size used throughout this proxy.
......
......@@ -191,6 +191,7 @@ namespace Titanium.Web.Proxy
// create a new connection if cache key changes.
// only gets hit when connection pool is disabled.
// or when prefetch task has a unexpectedly different connection.
if (serverConnection != null
&& (await getConnectionCacheKey(args, false,
clientConnection.NegotiatedApplicationProtocol)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment