Commit dfa78fd3 authored by Sophie Chang's avatar Sophie Chang Committed by Commit Bot

Deprecate hints proto fields that are not called by the client and will not be anymore

Change-Id: I1e8ea40a585589bf0ec3781897b498dd94a28d25
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2028260Reviewed-by: default avatarMichael Crouse <mcrouse@chromium.org>
Commit-Queue: Sophie Chang <sophiechang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#738028}
parent fd90b67d
...@@ -579,7 +579,7 @@ TEST_F(OptimizationGuideHintsManagerTest, ParseTwoConfigVersions) { ...@@ -579,7 +579,7 @@ TEST_F(OptimizationGuideHintsManagerTest, ParseTwoConfigVersions) {
optimization1->set_optimization_type( optimization1->set_optimization_type(
optimization_guide::proto::RESOURCE_LOADING); optimization_guide::proto::RESOURCE_LOADING);
optimization_guide::proto::ResourceLoadingHint* resource_loading_hint1 = optimization_guide::proto::ResourceLoadingHint* resource_loading_hint1 =
optimization1->add_resource_loading_hints(); optimization1->mutable_previews_metadata()->add_resource_loading_hints();
resource_loading_hint1->set_loading_optimization_type( resource_loading_hint1->set_loading_optimization_type(
optimization_guide::proto::LOADING_BLOCK_RESOURCE); optimization_guide::proto::LOADING_BLOCK_RESOURCE);
resource_loading_hint1->set_resource_pattern("news_cruft.js"); resource_loading_hint1->set_resource_pattern("news_cruft.js");
......
...@@ -57,6 +57,8 @@ message GetHintsRequest { ...@@ -57,6 +57,8 @@ message GetHintsRequest {
// Response to the GetHints request. // Response to the GetHints request.
message GetHintsResponse { message GetHintsResponse {
reserved 2;
// An ordered list containing hints for key/optimization combinations. // An ordered list containing hints for key/optimization combinations.
// //
// It is guaranteed that there will only be a single hint per key and key // It is guaranteed that there will only be a single hint per key and key
...@@ -71,10 +73,6 @@ message GetHintsResponse { ...@@ -71,10 +73,6 @@ message GetHintsResponse {
// hints from (HOST_SUFFIX,sports.cnn.com). // hints from (HOST_SUFFIX,sports.cnn.com).
repeated Hint hints = 1; repeated Hint hints = 1;
// The maximum duration in which the hints provided in this response should
// be retained in the client cache.
optional Duration max_cache_duration = 2 [deprecated = true];
// A set of hint keys to remove from the client cache. // A set of hint keys to remove from the client cache.
// //
// It is guaranteed that all entries in this list were provided by the client // It is guaranteed that all entries in this list were provided by the client
...@@ -148,23 +146,9 @@ enum KeyRepresentation { ...@@ -148,23 +146,9 @@ enum KeyRepresentation {
} }
message Optimization { message Optimization {
reserved 2, 3;
// The type of optimization the hint applies to. // The type of optimization the hint applies to.
optional OptimizationType optimization_type = 1; optional OptimizationType optimization_type = 1;
// A percent value to inflate the number of received bytes by for the purposes
// of data savings calculations in the client.
//
// If this value is set to 0, the client should use its configured default.
//
// Ex: If the received bytes is 100 and the inflation_percent is 30, the
// inflated bytes calculated by the client will be 30 in order to have a total
// consumed bytes value of 130.
optional int64 inflation_percent = 2 [deprecated = true];
// An ordered set of resource loading hints for OptimizationType
// RESOURCE_LOADING.
//
// Only the first ResourceLoadingHint record that matches a target resource
// URL will be applied to that resource.
repeated ResourceLoadingHint resource_loading_hints = 3 [deprecated = true];
// The experiment name that activates the optimization. // The experiment name that activates the optimization.
// //
// If a non-empty name is provided, the optimization will be disabled unless // If a non-empty name is provided, the optimization will be disabled unless
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment