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

Unified Diff: net/url_request/sdch_dictionary_fetcher.cc

Issue 2849263003: Network traffic annotation added to SDCH Dictionary Fetcher. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/sdch_dictionary_fetcher.cc
diff --git a/net/url_request/sdch_dictionary_fetcher.cc b/net/url_request/sdch_dictionary_fetcher.cc
index e51d9581a055c4bffc637d03564cd89b4a5f7305..11d11666462cfe8a16a832e4da1bfc420972acd5 100644
--- a/net/url_request/sdch_dictionary_fetcher.cc
+++ b/net/url_request/sdch_dictionary_fetcher.cc
@@ -19,6 +19,7 @@
#include "net/http/http_response_headers.h"
#include "net/log/net_log_event_type.h"
#include "net/log/net_log_with_source.h"
+#include "net/traffic_annotation/network_traffic_annotation.h"
#include "net/url_request/redirect_info.h"
#include "net/url_request/url_request_context.h"
#include "net/url_request/url_request_status.h"
@@ -278,7 +279,28 @@ int SdchDictionaryFetcher::DoSendRequest(int rv) {
FetchInfo info;
bool success = fetch_queue_->Pop(&info);
DCHECK(success);
- current_request_ = context_->CreateRequest(info.url, IDLE, this);
+ net::NetworkTrafficAnnotationTag traffic_annotation =
+ net::DefineNetworkTrafficAnnotation("...", R"(
Randy Smith (Not in Mondays) 2017/05/02 15:37:36 I believe from reading the proto and definitions t
Ramin Halavati 2017/05/03 05:55:40 Done.
+ semantics {
+ sender: "..."
Randy Smith (Not in Mondays) 2017/05/02 15:37:35 So this is tricky and I'm not sure what to do here
Ramin Halavati 2017/05/03 05:55:40 Thank you very much for description, but sender he
Randy Smith (Not in Mondays) 2017/05/03 12:58:42 That's fine.
Ramin Halavati 2017/05/04 04:36:28 Done.
+ description: "..."
Randy Smith (Not in Mondays) 2017/05/02 15:37:35 The Chrome Network Stack can use less bandwidth an
Ramin Halavati 2017/05/03 05:55:40 Done.
+ trigger: "..."
Randy Smith (Not in Mondays) 2017/05/02 15:37:36 A response to a previous URL request indicated tha
Ramin Halavati 2017/05/03 05:55:40 Done.
+ data: "..."
Randy Smith (Not in Mondays) 2017/05/02 15:37:36 The server is sending a dictionary of common 'phra
Ramin Halavati 2017/05/03 05:55:40 This field should refer to data that this request
Randy Smith (Not in Mondays) 2017/05/03 12:58:42 Ah, sorry, data sent to the server. Yes, the URL
+ destination: WEBSITE/GOOGLE_OWNED_SERVICE/OTHER/LOCAL
Randy Smith (Not in Mondays) 2017/05/02 15:37:36 I think WEBSITE is the right answer here, but not
Ramin Halavati 2017/05/03 05:55:40 So my understanding is Google has no role in compr
Randy Smith (Not in Mondays) 2017/05/03 12:58:42 Google is one of the websites that has used SDCH,
Ramin Halavati 2017/05/04 04:36:28 Thank you.
+ }
+ policy {
+ cookies_allowed: false
+ setting: "..."
Randy Smith (Not in Mondays) 2017/05/02 15:37:36 Disabled in chrome. Can only be enabled in non-Ch
Ramin Halavati 2017/05/03 05:55:40 Done.
+ chrome_policy {
+ [POLICY_NAME] {
+ policy_options {mode: MANDATORY/RECOMMENDED/UNSET}
+ [POLICY_NAME]: ... //(value to disable it)
+ }
+ }
+ policy_exception_justification: "..."
+ })");
+ current_request_ =
+ context_->CreateRequest(info.url, IDLE, this, traffic_annotation);
int load_flags = LOAD_DO_NOT_SEND_COOKIES | LOAD_DO_NOT_SAVE_COOKIES;
if (info.cache_only)
load_flags |= LOAD_ONLY_FROM_CACHE | LOAD_SKIP_CACHE_VALIDATION;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698