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

Unified Diff: net/http/http_server_properties.h

Issue 1572753003: QUIC - Allow cronet apps to specify how many server configs are to be (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: load all server configs from disk Created 4 years, 11 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_server_properties.h
diff --git a/net/http/http_server_properties.h b/net/http/http_server_properties.h
index 85b7285acb232a01ba9c9b9a8534e1b29164f185..cac13419a5abfb29dbb4d0c17e29fffce0332523 100644
--- a/net/http/http_server_properties.h
+++ b/net/http/http_server_properties.h
@@ -217,7 +217,7 @@ typedef base::MRUCache<HostPortPair, ServerNetworkStats> ServerNetworkStatsMap;
typedef base::MRUCache<QuicServerId, std::string> QuicServerInfoMap;
// Persist 5 QUIC Servers. This is mainly used by cronet.
-const int kMaxQuicServersToPersist = 5;
+const size_t kMaxQuicServersToPersist = 5;
extern const char kAlternateProtocolHeader[];
extern const char kAlternativeServiceHeader[];
@@ -381,6 +381,13 @@ class NET_EXPORT HttpServerProperties {
// Returns all persistent QuicServerInfo objects.
virtual const QuicServerInfoMap& quic_server_info_map() const = 0;
+ // Returns the number of server configs (QuicServerInfo objects) persisted.
+ virtual int number_of_server_configs_stored_in_properties() const = 0;
+
+ // Sets the number of server configs (QuicServerInfo objects) to be persisted.
+ virtual void set_number_of_server_configs_stored_in_properties(
+ int number_of_server_configs_stored_in_properties) = 0;
+
private:
DISALLOW_COPY_AND_ASSIGN(HttpServerProperties);
};

Powered by Google App Engine
This is Rietveld 408576698