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

Unified Diff: net/http/http_network_session.h

Issue 1901533002: Implementation of network level throttler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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/http/http_network_session.h
diff --git a/net/http/http_network_session.h b/net/http/http_network_session.h
index c77953924bc9b8e20bd0bd9c1346dd7244952c96..1154fd0371df4a15acd1af0bb41c918a74741850 100644
--- a/net/http/http_network_session.h
+++ b/net/http/http_network_session.h
@@ -18,6 +18,7 @@
#include "base/threading/non_thread_safe.h"
#include "net/base/host_port_pair.h"
#include "net/base/net_export.h"
+#include "net/base/network_stream_throttler.h"
#include "net/dns/host_resolver.h"
#include "net/http/http_auth_cache.h"
#include "net/http/http_stream_factory.h"
@@ -239,6 +240,7 @@ class NET_EXPORT HttpNetworkSession
HttpStreamFactory* http_stream_factory_for_websocket() {
return http_stream_factory_for_websocket_.get();
}
+ NetworkStreamThrottler* throttler() { return &network_stream_throttler_; }
NetLog* net_log() {
return net_log_;
}
@@ -290,6 +292,7 @@ class NET_EXPORT HttpNetworkSession
scoped_ptr<HttpStreamFactory> http_stream_factory_;
scoped_ptr<HttpStreamFactory> http_stream_factory_for_websocket_;
std::set<HttpResponseBodyDrainer*> response_drainers_;
+ NetworkStreamThrottler network_stream_throttler_;
NextProtoVector next_protos_;
bool enabled_protocols_[NUM_VALID_ALTERNATE_PROTOCOLS];

Powered by Google App Engine
This is Rietveld 408576698