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

Update hints.proto to include new URL-keyed hints API.

This change adds support for URL-keyed requests and hints to be
provided by the optimization guide.

Bug: 1036490
Change-Id: Ic261c776a9b8ec54158faff2ac90be81d5f8cd07
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1979350Reviewed-by: default avatarMichael Crouse <mcrouse@chromium.org>
Commit-Queue: Sophie Chang <sophiechang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#727779}
parent 261096cf
......@@ -27,12 +27,21 @@ message HostInfo {
optional MatchedHintInfo matched_hint = 2;
}
// Information about a URL to request hints for.
message UrlInfo {
// The URL that the client is requesting information for.
optional string url = 1;
}
// Request to return a set of hints that guide what optimizations to perform
// on those hosts.
message GetHintsRequest {
// Information about the set of hosts to retrieve hints for.
repeated HostInfo hosts = 1;
// Information about the set of URLs to retrieve hints for.
repeated UrlInfo urls = 4;
// The set of optimization types that the requesting client can support
// and perform.
//
......@@ -124,6 +133,11 @@ enum KeyRepresentation {
// Example: A host suffix of example.com would match pages with host
// sports.example.com, but not fooexample.com.
HOST_SUFFIX = 1;
// The full URL to match.
//
// This will be an exact match of a page load URL, including query params and
// fragments.
FULL_URL = 2;
}
message Optimization {
......@@ -206,6 +220,8 @@ message Hint {
// It is expected that this version be sent along with subsequent requests
// for hosts that match this hint.
optional string version = 5;
// The maximum duration for which the hint should be used for.
optional Duration max_cache_duration = 6;
}
// Configuration and data for a Bloom filter.
......
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