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

Side by Side Diff: net/base/sdch_manager.h

Issue 40319: Use filter context to track stats better in SDCH filtering (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/base/sdch_filter_unittest.cc ('k') | net/url_request/url_request_http_job.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Provides global database of differential decompression dictionaries for the 5 // Provides global database of differential decompression dictionaries for the
6 // SDCH filter (processes sdch enconded content). 6 // SDCH filter (processes sdch enconded content).
7 7
8 // Exactly one instance of SdchManager is built, and all references are made 8 // Exactly one instance of SdchManager is built, and all references are made
9 // into that collection. 9 // into that collection.
10 // 10 //
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 DOMAIN_BLACKLIST_INCLUDES_TARGET = 61, 112 DOMAIN_BLACKLIST_INCLUDES_TARGET = 61,
113 113
114 // Problematic decode recovery methods. 114 // Problematic decode recovery methods.
115 META_REFRESH_RECOVERY = 70, // Dictionary not found. 115 META_REFRESH_RECOVERY = 70, // Dictionary not found.
116 // defunct = 71, // Almost the same as META_REFRESH_UNSUPPORTED. 116 // defunct = 71, // Almost the same as META_REFRESH_UNSUPPORTED.
117 // defunct = 72, // Almost the same as CACHED_META_REFRESH_UNSUPPORTED. 117 // defunct = 72, // Almost the same as CACHED_META_REFRESH_UNSUPPORTED.
118 // defunct = 73, // PASSING_THROUGH_NON_SDCH plus DISCARD_TENTATIVE_SDCH. 118 // defunct = 73, // PASSING_THROUGH_NON_SDCH plus DISCARD_TENTATIVE_SDCH.
119 META_REFRESH_UNSUPPORTED = 74, // Unrecoverable error. 119 META_REFRESH_UNSUPPORTED = 74, // Unrecoverable error.
120 CACHED_META_REFRESH_UNSUPPORTED = 75, // As above, but pulled from cache. 120 CACHED_META_REFRESH_UNSUPPORTED = 75, // As above, but pulled from cache.
121 PASSING_THROUGH_NON_SDCH = 76, // Non-html tagged as sdch but malformed. 121 PASSING_THROUGH_NON_SDCH = 76, // Non-html tagged as sdch but malformed.
122 INCOMPLETE_SDCH_CONTENT = 77, // Last window was not completely decoded. 122 INCOMPLETE_SDCH_CONTENT = 77, // Last window was not completely decoded.
123 123
124 124
125 // Common decoded recovery methods. 125 // Common decoded recovery methods.
126 META_REFRESH_CACHED_RECOVERY = 80, // Probably startup tab loading. 126 META_REFRESH_CACHED_RECOVERY = 80, // Probably startup tab loading.
127 DISCARD_TENTATIVE_SDCH = 81, // Server decided not to use sdch. 127 DISCARD_TENTATIVE_SDCH = 81, // Server decided not to use sdch.
128 128
129 // Non SDCH problems, only accounted for to make stat counting complete 129 // Non SDCH problems, only accounted for to make stat counting complete
130 // (i.e., be able to be sure all dictionary advertisements are accounted 130 // (i.e., be able to be sure all dictionary advertisements are accounted
131 // for). 131 // for).
132 132
133 UNFLUSHED_CONTENT = 90, // Possible error in filter chaining. 133 UNFLUSHED_CONTENT = 90, // Possible error in filter chaining.
134 MISSING_TIME_STATS = 91, // Should never happen. 134 MISSING_TIME_STATS = 91, // Should never happen.
135 CACHE_DECODED = 92, // Hence there are no timing stats recorded. 135 CACHE_DECODED = 92, // No timing stats recorded.
136 OVER_10_MINUTES = 93, // No timing stats will be recorded.
137 UNINITIALIZED = 94, // Filter never even got initialized.
138 PRIOR_TO_DICTIONARY = 95, // We hadn't even parsed a dictionary selector.
139 DECODE_ERROR = 96, // Something went wrong during decode.
136 140
137 MAX_PROBLEM_CODE // Used to bound histogram. 141 MAX_PROBLEM_CODE // Used to bound histogram.
138 }; 142 };
139 143
140 // Use the following static limits to block DOS attacks until we implement 144 // Use the following static limits to block DOS attacks until we implement
141 // a cached dictionary evicition strategy. 145 // a cached dictionary evicition strategy.
142 static const size_t kMaxDictionarySize; 146 static const size_t kMaxDictionarySize;
143 static const size_t kMaxDictionaryCount; 147 static const size_t kMaxDictionaryCount;
144 148
145 // There is one instance of |Dictionary| for each memory-cached SDCH 149 // There is one instance of |Dictionary| for each memory-cached SDCH
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 DomainCounter blacklisted_domains_; 330 DomainCounter blacklisted_domains_;
327 331
328 // Support exponential backoff in number of domain accesses before 332 // Support exponential backoff in number of domain accesses before
329 // blacklisting expires. 333 // blacklisting expires.
330 DomainCounter exponential_blacklist_count; 334 DomainCounter exponential_blacklist_count;
331 335
332 DISALLOW_COPY_AND_ASSIGN(SdchManager); 336 DISALLOW_COPY_AND_ASSIGN(SdchManager);
333 }; 337 };
334 338
335 #endif // NET_BASE_SDCH_MANAGER_H_ 339 #endif // NET_BASE_SDCH_MANAGER_H_
OLDNEW
« no previous file with comments | « net/base/sdch_filter_unittest.cc ('k') | net/url_request/url_request_http_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698