Skip to content

Commit

Permalink
actually fixed issue
Browse files Browse the repository at this point in the history
  • Loading branch information
crystallambert@chromium.org committed Aug 23, 2018
1 parent c0caa6e commit f733d3e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ inlineCSS: .amp-wp-inline-329fdb7771c10d07df9eb73273c95a60{font-weight:400;}
<li class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60"><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">A centralized request manager that controls the timing and availability of resource requests from web components on AMP pages.</span></li>
</ol><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">Let’s look a bit closer at the second mechanism: Whenever an AMP page loads any resource, such as images, videos, ads, analytics requests, tweets, or any of dozens of other types of resources, the associated network requests are controlled by a central resource management mechanism. This resource manager, in addition to performing many other functions, also ensures that requests that are not allowed during the prerendering phase of a document lifecycle are held back until the document learns that the user expressed intent to see the page.</span></p><p><amp-img class="alignnone size-full wp-image-2111 amp-wp-enforced-sizes" src="https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-e1532367183277.png?w=660" alt="privacy-and-user-choice-in-amp_s-software-architecture-blog-post-e1532367137299.png" srcset="https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-e1532367183277.png 344w, https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-e1532367183277.png?w=141 141w, https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-e1532367183277.png?w=281 281w" sizes="(min-width: 344px) 344px, 100vw" width="344" height="367"></amp-img><br/><i><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">Diagram of the process to load a resource in the AMP JS library.</span></i></p><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">This is the key architectural feature of AMP that makes it uniquely suited to implement more sophisticated privacy controls on top of this baseline mechanism.</span></p><h2><b>An architecture for supporting user choice</b></h2><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">The previous paragraph talks about how AMP controls resource request timing to ensure that certain requests made during the prerendering phase are only actually made after a user has expressed intent to visit a page. From a software architecture point of view, this introduces a central mechanism to control request timing, making it relatively easy to then introduce additional rules, including rules specified by the publisher of the page, for delaying requests on top of the pre-rendering specific rules. </span></p><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">For example, one such publisher-specified rule could be to delay any ad requests on an AMP page until the publisher has obtained sufficient user consent to make such ad requests or share ads-related data with an ad vendor. </span></p><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">For each AMP web component (such as the </span><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">amp-ad</span><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60"> and the </span><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">amp-img</span><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60"> elements), a publisher can specify that the associated resources should only be loaded if the user has provided consent that the publisher has determined is needed to load and display the respective resource.</span></p><p><amp-img class="alignnone size-full wp-image-2112 amp-wp-enforced-sizes" src="https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-1-e1532367237552.png?w=660" alt="privacy-and-user-choice-in-amp_s-software-architecture-blog-post-1.png" srcset="https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-1-e1532367237552.png 619w, https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-1-e1532367237552.png?w=145 145w, https://amphtml.files.wordpress.com/2018/07/privacy-and-user-choice-in-amp_s-software-architecture-blog-post-1-e1532367237552.png?w=291 291w" sizes="(min-width: 619px) 619px, 100vw" width="619" height="639"></amp-img><br/><i><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">Diagram of the process that determines the flow to requesting a resource in the AMP JS library. </span></i></p><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">While a publisher may still need to perform an audit of the types of AMP web components they load on their page and determine whether any form of user consent may be needed to display them, having a unified mechanism to control the behavior of all resource types that may be included in a page–from images, over ads, to analytics–should make it easier for a publisher to gain confidence that they applied the consent treatment to the full spectrum of resources and behaviors where it is needed.</span></p><p><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">This post looked at privacy-enhancing functionality from a software architecture point of view. For concrete steps to implement user choice flows in AMP documents, please check out this </span><a href="https://www.ampproject.org/latest/blog/new-tools-for-building-user-controls-in-amp-pages/"><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">blog post</span></a><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">.</span></p><p><i><span class="amp-wp-inline-329fdb7771c10d07df9eb73273c95a60">Posted by <a href="https://twitter.com/cramforce">Malte Ubl</a>, Tech Lead of the AMP Project.</span></i></p> </div>



</div>

2 changes: 1 addition & 1 deletion scripts/update_blog_links.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ ${ body }
/* Converts the provided RSS blog item into a consistent format. */
function onParseBlogPost(item) {
var authorInBody = item.description.match(/\>Posted by ([^,]+),([^\<]+)/);
var author = authorInBody ? authorInBody[1] : item.author;
var author = authorInBody ? authorInBody[1].replace(/<[^>]+>/g, '') : item.author;
var role = authorInBody ? authorInBody[2] : '';

return {
Expand Down

0 comments on commit f733d3e

Please sign in to comment.