Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(624)

Unified Diff: net/socket/client_socket_pool_manager.cc

Issue 7283018: Introduce a policy to control the maximal number of connections per proxy server. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Moved setting that policy to a really early point in the initialization of the system. Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/socket/client_socket_pool_manager.cc
diff --git a/net/socket/client_socket_pool_manager.cc b/net/socket/client_socket_pool_manager.cc
index f26f876989fb144229a63570eeb59a6e6c038170..9f5cbf7a841f9989e06637f303eec025f880679f 100644
--- a/net/socket/client_socket_pool_manager.cc
+++ b/net/socket/client_socket_pool_manager.cc
@@ -27,6 +27,8 @@
namespace net {
+const int kDefaultMaxSocketsPerProxyServer = 32;
+
namespace {
// Total limit of sockets.
@@ -40,7 +42,7 @@ int g_max_sockets_per_group = 6;
// The max number of sockets to allow per proxy server. This applies both to
// http and SOCKS proxies. See http://crbug.com/12066 and
// http://crbug.com/44501 for details about proxy server connection limits.
-int g_max_sockets_per_proxy_server = 32;
+int g_max_sockets_per_proxy_server = kDefaultMaxSocketsPerProxyServer;
// Appends information about all |socket_pools| to the end of |list|.
template <class MapType>
@@ -567,6 +569,7 @@ void ClientSocketPoolManager::set_max_sockets_per_proxy_server(
// exceed the max number of sockets per proxy server.
DCHECK_LE(g_max_sockets_per_group, socket_count);
g_max_sockets_per_proxy_server = socket_count;
+ LOG(ERROR) << "### Set the count to : " << socket_count;
willchan no longer on Chromium 2011/07/07 17:22:04 I presume this is for debugging. If so, please kil
pastarmovj 2011/07/08 10:49:39 Done.
}
Value* ClientSocketPoolManager::SocketPoolInfoToValue() const {
« chrome/browser/net/net_pref_observer.cc ('K') | « net/socket/client_socket_pool_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698