Explore AMP-based Previews |
|||||
Issue descriptionOur current thinking about client-side Previews focuses on degrading the rendering of a page based on the original HTML and other content of that page. Likewise, server-side Previews are currently based on the full page. To my knowledge we have no current plans leveraging the existence of AMP variants of pages for Previews. If a given page has an AMP variant, we could consider using it as the basis for the Preview instead: - For a server-generated Preview, just serve the AMP page itself, or use the AMP page as the input to the Preview generator. - For a client-side Preview, redirect the browser to the AMP page (possibly applying other client-side transformations to that). Non-AMP pages should link to their AMP variants with markup like: <link rel="amphtml" href="https://www.example.com/url/to/amp/document.html"> So both the server and client can be aware of the existence of an AMP variant. For client-side AMP-based previews, we probably want to avoid the extra round-trip to get the HTML just to redirect to AMP, so we might consider generating a client-side hint of which sites are likely to have AMP variants (e.g., many popular news sites, etc.) and try AMP first in those cases. Welcome other suggestions and thoughts on this. Note that I am thinking of this strictly as a Preview -- that is, an extreme intervention for users on slow networks -- rather than trying to replace regular web pages with AMP pages more generally.
,
Feb 17 2017
I see that Bryan and Charles added some UMA to track the number of pages loaded from an AMP cache, but the numnber of hits is very low: https://uma.googleplex.com/p/chrome/histograms/?endDate=20170215&dayCount=1&histograms=PageLoad.Clients.AMPCache.ParseTiming.NavigationToParseStart&fixupData=true&otherVersions=true&showMax=true&filters=channel%2Ceq%2C1%2Cisofficial%2Ceq%2CTrue&implicitFilters=isofficial Bryan/Charles -- do you know what's up with this UMA? I don't think we necessarily need to block on getting more data before implementing something like this, if we can show that there's a performance win. Doing this server-side first might be the right approach since that would require zero (?) Chrome changes.
,
Feb 17 2017
Related: crbug.com/672466 which is about preferring AMP URLs in Zine suggestions.
,
Feb 17 2017
ryansturm@ added these histograms (thanks ryan!). Happy to support making them better, but there's some somewhat challenging work here. AMP page loads are somewhat unique and not always supported by the page load metrics infra. The main issues are that many navigations to AMP documents: 1. load the main AMP document in an iframe (AMP viewer, for example) 2. navigate to the AMP document using an in-page navigation managed at the JS layer RE: 1, pages that load their main content in an iframe have historically been uncommon, and supporting that use case in page load metrics added complexity, so we never got around to it. RE: 2, there's no canonical browser-level API to track in-page navigations managed by JS. In general, these types of navigations are free to do whatever they want, and there's no clear concept of when a navigation started, whether there's a main html resource being loaded, or what constitutes a 'first paint' etc. We have some bugs open related to these issues which people are welcome to tackle. I'd want to meet to discuss potential implementation details and make sure we're approaching the problem in a way that generalizes beyond AMP, if at all possible. https://bugs.chromium.org/p/chromium/issues/detail?id=661702 https://bugs.chromium.org/p/chromium/issues/detail?id=661701
,
Feb 27 2017
RE: comment #2, a server-side experiment that redirects to the AMP variant should be simple enough to implement. To measure the benefit we'd need to separate performance timings for such redirects from control -- I'm not sure we can re-use the existing metrics, but we should explore.
,
Sep 5 2017
Assigning to Raj since he is currently working on a client side experiment for AMP redirects.
,
Oct 30 2017
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by bengr@chromium.org
, Feb 16 2017Status: Assigned (was: Untriaged)