Getting to 2nd Base with your Content Delivery Network Mike Brittain Engineering Architect.

Slides:



Advertisements
Similar presentations
CS193H: High Performance Web Sites Lecture 17: Rule 14 – Make Ajax Cacheable Steve Souders Google
Advertisements

PACS – 06/21/14 1 Cache? What is caching? A way to increase the average rate of a process by preferentially using a copy of data in a faster, closer, probably.
1 Content Delivery Networks iBAND2 May 24, 1999 Dave Farber CTO Sandpiper Networks, Inc.
Lecture 12, : The Internet, Summer : The Internet Lecture 12: Scalable services David O’Hallaron School of Computer Science and Department.
HyperText Transfer Protocol (HTTP)
1 Caching in HTTP Representation and Management of Data on the Internet.
An Analysis of Internet Content Delivery Systems Stefan Saroiu, Krishna P. Gommadi, Richard J. Dunn, Steven D. Gribble, and Henry M. Levy Proceedings of.
How the web works: HTTP and CGI explained
What’s a Web Cache? Why do people use them? Web cache location Web cache purpose There are two main reasons that Web cache are used:  to reduce latency.
1 The World Wide Web Architectural Overview Static Web Documents Dynamic Web Documents HTTP – The HyperText Transfer Protocol Performance Enhancements.
Web, HTTP and Web Caching
Hypertext Transfer Protocol Information Systems 337 Prof. Harry Plantinga.
1 K. Salah Module 2.1: Application Layer Application-level protocols provide high-level services –Web and HTTP –DNS –Electronic mail –Remote login –FTP.
High Performance Websites (Based on Steve Souder’s lecture) By Bhoomi Patel.
HTTP HyperText Transfer Protocol Part 3.
2/9/2004 Web and HTTP February 9, /9/2004 Assignments Due – Reading and Warmup Work on Message of the Day.
Nikolay Kostov Telerik Corporation
Web Cache. Introduction what is web cache?  Introducing proxy servers at certain points in the network that serve in caching Web documents for faster.
Towards Understanding Modern Web Traffic
ITM352 Javascript and Dynamic Web Pages: Client Side Processing.
Mark Phillip markphillip.com 200s, 304s, Expires Headers, HTTP Compression, And You.
On the Use and Performance of Content Distribution Networks Balachander Krishnamurthy Craig Wills Yin Zhang Presenter: Wei Zhang CSE Department of Lehigh.
1 Caching  Temporary storage of frequently accessed data (duplicating original data stored somewhere else)  Reduces access time/latency for clients 
HTTP Caching & Cache-Busting for Content Publishers Michael J. Radwin O’Reilly Open Source Convention July 28, 2004.
Krerk Piromsopa. Web Caching Krerk Piromsopa. Department of Computer Engineering. Chulalongkorn University.
Web Caching: Replication on the World Wide Web Jonathan Bulava CSC8530 – Distributed Systems Dr. Paul Schragger.
Real World Examples – Part II 7/26/2013Miro Remias, Sr. Solution Architect.
CSC 2720 Building Web Applications Getting and Setting HTTP Headers (With PHP Examples)
TCP/IP Protocol Suite 1 Chapter 22 Upon completion you will be able to: World Wide Web: HTTP Understand the components of a browser and a server Understand.
Rensselaer Polytechnic Institute Shivkumar Kalvanaraman, Biplab Sikdar 1 The Web: the http protocol http: hypertext transfer protocol Web’s application.
Week 11: Application Layer1 Web and HTTP First some jargon r Web page consists of objects r Object can be HTML file, JPEG image, Java applet, audio file,…
Traffic Control in Apache Jed Reynolds Blog.Bitratchet.com Where in your web site do you need traffic control?
1 Client-Side Includes: Fast Access to Dynamic Content Fragment 1 Fragment 2 Uses open ESI language to fragment pages –Exception handling –Conditional.
Instructor, Dr. Khalili Bahram Jeevan Kumar Gogineni.
2: Application Layer1 Chapter 2 outline r 2.1 Principles of app layer protocols r 2.2 Web and HTTP r 2.3 FTP r 2.4 Electronic Mail r 2.5 DNS r 2.6 Socket.
Hui Zhang, Fall Computer Networking Web, HTTP, Caching.
Web Server Design Week 4 Old Dominion University Department of Computer Science CS 495/595 Spring 2010 Martin Klein 2/03/10.
CSE 461 HTTP and the Web. This Lecture  HTTP and the Web (but not HTML)  Focus  How do Web transfers work?  Topics  HTTP, HTTP1.1  Performance Improvements.
1 Caching in HTTP Representation and Management of Data on the Internet.
CIS679: Lecture 13 r Review of Last Lecture r More on HTTP.
HTTP support for caching & replication. Conditional requests Server executes conditional request. Responds with a message body only if the condition is.
1-1 HTTP request message GET /somedir/page.html HTTP/1.1 Host: User-agent: Mozilla/4.0 Connection: close Accept-language:fr request.
Ajax. –Asynchronous JavaScript and XML –Umbrella term for technologies that often: Use client-side scripting for layout and formatting Use less than full.
NWS Experiences in Outsourcing Web Content Delivery Robert Bunge NWS OCIO 11/2/05.
Web Cache Consistency. “Requirements of performance, availability, and disconnected operation require us to relax the goal of semantic transparency.”
Web Server Design Week 7 Old Dominion University Department of Computer Science CS 495/595 Spring 2010 Martin Klein 2/24/10.
Web Technologies Lecture 1 The Internet and HTTP.
27.1 Chapter 27 WWW and HTTP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
EE 122: Lecture 21 (HyperText Transfer Protocol - HTTP) Ion Stoica Nov 20, 2001 (*)
1 COMP 431 Internet Services & Protocols HTTP Persistence & Web Caching Jasleen Kaur February 11, 2016.
Overview on Web Caching COSC 513 Class Presentation Instructor: Prof. M. Anvari Student name: Wei Wei ID:
Week 11: Application Layer 1 Web and HTTP r Web page consists of objects r Object can be HTML file, JPEG image, Java applet, audio file,… r Web page consists.
1 The World Wide Web Architectural Overview Static Web Documents Dynamic Web Documents HTTP – The HyperText Transfer Protocol Performance Enhancements.
Web Cache. What is Cache? Cache is the storing of data temporarily to improve performance. Cache exist in a variety of areas such as your CPU, Hard Disk.
MICROSOFT AJAX CDN (CONTENT DELIVERY NETWORK) Make Your ASP.NET site faster to retrieve.
Fault – Tolerant Distributed Multimedia Streaming Web Application By Nirvan Sagar – Srishti Ganjoo – Syed Shahbaaz Safir
JQuery Fundamentals Introduction Tutorial Videos
Essential tools for implementing and testing websites
Block 5: An application layer protocol: HTTP
HTTP request message: general format
Caching Temporary storage of frequently accessed data (duplicating original data stored somewhere else) Reduces access time/latency for clients Reduces.
Ad-blocker circumvention System
CloudFront: Living on the Edge
Post-relational databases What's wrong with web development?
Web Caching? Web Caching:.
AJAX.
Internet Applications
ECE 671 – Lecture 16 Content Distribution Networks
CSE 461 HTTP and the Web.
JavaScript & jQuery AJAX.
Presentation transcript:

Getting to 2nd Base with your Content Delivery Network Mike Brittain Engineering Architect

Overview 1. Measure your performance 2. Tweak your cache TTLs 3. Cache dynamic objects 4. Cache whole pages 5. Inspect origin hits 6. Use proper HTTP headers 7. Use multiple CDNs 8. Review CDN documentation 9. Engage your vendor

Overview 20 Minutes

Overview 1. Cache dynamic objects 2. Inspect origin traffic 3. Cache HTML pages

Typical Setup

CDN Storage $$$

Origin Pull CDN lingo for “reverse proxy”

Response Headers Cache-control: max-age=3600 Last-Modified: Mon, 16 Mar … ETag: “82c e2a”

Revalidation Requests GET /images/generated.css HTTP/1.1 Host: origin.example.com If-Modified-Since: Mon, 16 Mar … If-None-Match: ”82c e2a” HTTP/ OK Content-Length: or... HTTP/ Not Modified $$$ $

Review Origin Logs RequestsURLSize 28/images/logo.gif2 KB 17/images/nav_tabs.png5 KB 4,613/images/annual_report.ppt16 MB 31/images/flames.gif13 KB

Avoid Double Paying 16 MB x 0.35/GB ≈ $25 (CDN) 16 MB x 0.50/GB ≈ $36 (origin) $61

Avoid Double Paying 16 MB x 0.35/GB ≈ $25 (CDN) 16 MB x 0.50/GB ≈ $0.18 (origin) $25 - ish

Cache HTML Pages

Page built just for Mike

Cache HTML Pages Serve generic version to the CDN Use client-side logic for personalization

Cache HTML Pages Replace generic sections with tailored versions Cookies, JavaScript

Cache HTML Pages Track short history of user interactions Fresh data only where needed Ajax, Cookies, JavaScript

Cache HTML Pages Use tracking pixels for page views Real time data with Ajax, or fake it Ajax, Cookies, JavaScript

Cache HTML Pages Search Results, HTML frag., Public APIs, XML, JSON, RSS Do you GET it?

Cache HTML Pages

TTLs of 3 mins to 1 hr Psst… under 60 seconds is okay, too.

Cache HTML Pages 92%

Thank You Slides, etc. Questions

Wait… You’re still here?

No, seriously… go away!

HTTP Headers cURL, telnet, Charles, Fiddler, Firebug, etc.

CDNs Fail Plan B  Split traffic between (similar) CDNs  Origin servers  Cloud storage

CDNs Fail

Amazon CloudFront: $0.17/GB* Rackspace Cloud Files: $0.22/GB JetS3t, Cyberduck, Transit, S3 Browser, S3Fox Plug-in, s3sync.rb, APIs, etc.

Multiple CDNs Cost vs. Performance Time Views