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

Unified Diff: components/favicon/core/large_icon_service.cc

Issue 2794343002: Network traffic annotation added to image_data_fetcher. (Closed)
Patch Set: Annotation updated. Created 3 years, 7 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: components/favicon/core/large_icon_service.cc
diff --git a/components/favicon/core/large_icon_service.cc b/components/favicon/core/large_icon_service.cc
index 8920f7c49631db6cefd1240e1bfe3ef6a50accaf..3fb751f849ba1c78485bbfc8d4aa820eeb24acd4 100644
--- a/components/favicon/core/large_icon_service.cc
+++ b/components/favicon/core/large_icon_service.cc
@@ -364,10 +364,35 @@ void LargeIconService::
image_fetcher_->SetDataUseServiceName(
data_use_measurement::DataUseUserData::LARGE_ICON_SERVICE);
+ net::NetworkTrafficAnnotationTag traffic_annotation =
+ net::DefineNetworkTrafficAnnotation("favicon_component", R"(
+ semantics {
+ sender: "Favicon Component"
+ description:
+ "Sends a request to a Google server to retrieve the favicon bitmap "
+ "for a page URL."
+ trigger:
+ "A request can be sent for signed-in users when Chrome does not "
+ "have a favicon for a particular page. This is done in two "
+ "scenarios:\n"
+ " 1- For articles suggestions on the new tab page (URLs are public "
+ " and provided by Google).\n"
+ " 2- For server-suggested most visited tiles on the new tab page "
+ " (User gets these URLs from Google, only if history sync is "
+ " enabled)."
+ data: "Page URL and desired icon size."
+ destination: GOOGLE_OWNED_SERVICE
+ }
+ policy {
+ cookies_allowed: false
+ setting: "This feature cannot be disabled by settings."
msramek 2017/05/19 08:47:38 Since the trigger says "signed-in users", should t
Ramin Halavati 2017/05/19 09:03:37 But scenario one is not covered by this policy. I
+ policy_exception_justification: "Not implemented."
+ })");
image_fetcher_->StartOrQueueNetworkRequest(
server_request_url.spec(), server_request_url,
base::Bind(&OnFetchIconFromGoogleServerComplete, favicon_service_,
- page_url, callback));
+ page_url, callback),
+ traffic_annotation);
}
base::CancelableTaskTracker::TaskId

Powered by Google App Engine
This is Rietveld 408576698