Overview Content Delivery Computer Networking Lecture 15: The Web Peter Steenkiste. Fall 2016

Similar documents
1-1. Switching Networks (Fall 2010) EE 586 Communication and. September Lecture 10

CSC 257/457 Computer Networks. Fall 2017 MW 4:50 pm 6:05 pm CSB 601

Outline Computer Networking. HTTP Basics (Review) How to Mark End of Message? (Review)

Web, HTTP and Web Caching

CMSC 332 Computer Networking Web and FTP

HyperText Transfer Protocol

CSC 401 Data and Computer Communications Networks

CSEN 404 Introduction to Networks. Mervat AbuElkheir Mohamed Abdelrazik. ** Slides are attributed to J. F. Kurose

CSC 4900 Computer Networks:

CS 355. Computer Networking. Wei Lu, Ph.D., P.Eng.

Computer Networks. Wenzhong Li. Nanjing University

Chapter 2 Application Layer

CSEN 503 Introduction to Communication Networks

HTTP/2: What You Need to Know. Robert

Application Layer: HTTP

416 Distributed Systems. March 23, 2018 CDNs

Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP

CSC358 Week 2. Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright J.F Kurose and K.W. Ross, All Rights Reserved

Chapter 2 Application Layer

Application Protocols and HTTP

Lecture Overview : Computer Networking. Applications and Application-Layer Protocols. Client-Server Paradigm

Lecture 04: Application Layer (Part 01) Principles and the World Wide Web (HTTP) Dr. Anis Koubaa

Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP

Lecture 12. Application Layer. Application Layer 1

Web caches (proxy server) Applications (part 3) Applications (part 3) Caching example (1) More about Web caching

Chapter 2 Application Layer

Introduc)on to Computer Networks

Computer Networks. HTTP and more. Jianping Pan Spring /20/17 CSC361 1

CSCE 463/612 Networks and Distributed Processing Spring 2018

ELEC / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition

CSE/EE 461 HTTP and the Web

Computer Network Midterm Explain Internet protocol stack (1% each layer s name, 1% each layer s functions, 10% total)

CSCI-1680 WWW Rodrigo Fonseca

Chapter 2: Application Layer. Chapter 2 Application Layer. Some network apps. Application architectures. Chapter 2: Application layer

Schahin Rajab TCP or QUIC Which protocol is most promising for the future of the internet?

Web, HTTP, Caching, CDNs

Lecture Overview. Lecture 3 Design Philosophy & Applications. Internet Architecture. Priorities

Review of Previous Lecture

Foundations of Telematics

EECS 3214: Computer Network Protocols and Applications

PLEASE READ CAREFULLY BEFORE YOU START

PLEASE READ CAREFULLY BEFORE YOU START

Chapter 2 Application Layer

SPDY - A Web Protocol. Mike Belshe Velocity, Dec 2009

EE 122: HyperText Transfer Protocol (HTTP)

1. What is a Computer Network? interconnected collection of autonomous computers connected by a communication technology

CSCI-1680 WWW Rodrigo Fonseca

CS 43: Computer Networks. HTTP September 10, 2018

Lecture 6: Application Layer Web proxies, , and SMTP

CSCI 466 Midterm Networks Fall 2013

TCP so far Computer Networking Outline. How Was TCP Able to Evolve

PLEASE READ CAREFULLY BEFORE YOU START

Page # Lecture Overview. Lecture 3 Design Philosophy & Applications. Internet Architecture. Priorities. Survivability.

Chapter 2 Application Layer

COSC4377. Chapter 2: Outline

c) With the selective repeat protocol, it is possible for the sender to receive an ACK for a packet that falls outside of its current window.

Computer Networks - Midterm

Topics. TCP sliding window protocol TCP PUSH flag TCP slow start Bulk data throughput

Question Points Score total 100

Flash: an efficient and portable web server

EECS 122: Introduction to Computer Networks DNS and WWW. Internet Names & Addresses

Network Applications Principles of Network Applications

PLEASE READ CAREFULLY BEFORE YOU START

PLEASE READ CAREFULLY BEFORE YOU START

School of Engineering Department of Computer and Communication Engineering Semester: Fall Course: CENG415 Communication Networks

Improving HTTP Latency

A New Internet? RIPE76 - Marseille May Jordi Palet

HTTP and Web Content Delivery

Outline Computer Networking. TCP slow start. TCP modeling. TCP details AIMD. Congestion Avoidance. Lecture 18 TCP Performance Peter Steenkiste

Session 8. Reading and Reference. en.wikipedia.org/wiki/list_of_http_headers. en.wikipedia.org/wiki/http_status_codes

Applications & Application-Layer Protocols: The Web & HTTP

HTTPS is Fast and Hassle-free with Cloudflare

Web as a Distributed System

CS457 Transport Protocols. CS 457 Fall 2014

No, the bogus packet will fail the integrity check (which uses a shared MAC key).!

Hypertext Transport Protocol HTTP/1.1

Overview Computer Networking What is QoS? Queuing discipline and scheduling. Traffic Enforcement. Integrated services

CMPE150 Midterm Solutions

Content Distribu-on Networks (CDNs)

CS4/MSc Computer Networking. Lecture 3: The Application Layer

Q U E S T I O N 3 In the current version of IP (IPv4), the use of TCP and UDP headers differ in which of the following ways?

Name Student ID Department/Year. Midterm Examination. Introduction to Computer Networks Class#: 901 E31110 Fall 2006

Advanced Computer Networking. CYBR 230 Jeff Shafer University of the Pacific QUIC

Internet Content Distribution

CSE 3214: Computer Network Protocols and Applications. Midterm Examination

The Application Layer HTTP and FTP

90 Minute Optimization Life Cycle

Chapter 2 Application Layer. Lecture 4: principles of network applications. Computer Networking: A Top Down Approach

ECE 435 Network Engineering Lecture 10

Ch. 7: Benchmarks and Performance Tests

CPSC 441 COMPUTER COMMUNICATIONS MIDTERM EXAM SOLUTION

Web File Transmission by Object Packaging Performance Comparison with HTTP 1.0 and HTTP 1.1 Persistent Connection

CSE/EE 461 Lecture 13 Connections and Fragmentation. TCP Connection Management

PRACTICE QUESTIONS ON RESOURCE ALLOCATION

Transmission Control Protocol. ITS 413 Internet Technologies and Applications

A Library and Proxy for SPDY

CS 5520/ECE 5590NA: Network Architecture I Spring Lecture 13: UDP and TCP

Name Student ID Department/Year. Midterm Examination. Introduction to Computer Networks Class#: 901 E31110 Fall 2007

A taste of HTTP v1.1. additions. HTTP v1.1: introduces many complexities no longer an easy protocol to implement. G.Bianchi, G.Neglia, V.

A New Internet? Introduction to HTTP/2, QUIC and DOH

Transcription:

Overview Content Delivery 15-441 15-441 Computer Networking 15-641 Lecture 15: The Web Peter Steenkiste Fall 2016 www.cs.cmu.edu/~prs/15-441-f16 Web Protocol interactions HTTP versions Caching Cookies Peer-to-peer CDNs Video 3 Web history Internet Traffic History 1945: Vannevar Bush, As we may think, Atlantic Monthly, July, 1945. Describes the idea of a distributed hypertext system A memex that mimics the web of trails in our minds 1989: Tim Berners-Lee (CERN) writes internal proposal to develop a distributed hypertext system Connects a web of notes with links. Intended to help CERN physicists in large projects share and manage information 1990: TBL writes graphical browser for Next machines 1992-1994: NCSA/Mosaic/Netscape browser release PByte/month 100000 10000 1000 100 10 1 0.1 0.01 0.001 All Fixed Mobile Year 4 5 1

Typical Workload (Web Pages) HTTP 0.9/1.0 Multiple (typically small) objects per page File sizes Lots of small objects Heavy-tailed versus TCP Pareto distribution for tail 3-way handshake Lognormal for body of distribution Lots of slow starts Embedded references Extra connection state Number of embedded objects also Pareto Pr(X>x) = (x/x m ) -k This plays havoc with performance. Why? Solutions? One request/response per TCP connection Simple to implement Short transfers are very hard on TCP Multiple connection setups three-way handshake each time Several extra round trips added to transfer Many slow starts low throughput because of small window Never leave slow start for short transfers Loss recovery is poor when windows are small Lots of extra connections increase state and processing overhead 6 7 Single Transfer Example HTTP 1.1 0 RTT Client opens TCP connection 1 RTT for HTML Client parses HTML Client opens TCP connection for image Image begins to arrive 2 RTT 3 RTT 4 RTT Client FIN Server FIN Multiplex multiple transfers onto one TCP connection Avoid handshake and slow start when getting multiple objects from same Transfers can be pipelined, i.e., multiple outstanding requests Requests are handled in FIFO order by How to identify requests/responses? Delimiter Server must examine response for delimiter string Content-length and delimiter Must know size of transfer in advance Block-based transmission send in multiple length delimited blocks Store-and-forward wait for entire response and then use content-length 8 9 2

Persistent Connection Solution Some Challenges with HTTP 1.1 0 RTT for HTML index page 1 RTT Client parses HTML for image Image begins to arrive 2 RTT Client Server Head of line blocking: slow objects can delay all requests that follow E.g., objects from versus objects in cache Single slow object can delay many fast objects Browsers open multiple TCP connections to achieve parallel transfers Increases load on s and network HTTP headers are big Cost higher for small objects Embedded objects add RTT With small objects, RTT dominates 10 11 Example of Head of Line Blocking HTTP 2.0 to the Rescue Source: http://chimera.labs.oreilly.com/books/1230000000545/ch11.html Other objects could have been sent 12 Can multiplex many requests over a TCP connection AND Responses are carried over flow controlled streams avoids HOL blocking Streams can be prioritized by client based on how critical they are to rendering multiple prioritized parallel TCP streams Also: fewer handshakes and more traffic (help congestion control) HTTP headers are compressed A PUSH features allows to push embedded objects to the client without waiting for a client request Avoids an RTT What is the challenge? Default is to use TLS fall back on 1.1 otherwise 13 3

HTTP/2 Multi-Streams Multiplexing HTTP/2 Server Push HTTP/2 Binary Framing https://tools.ietf.org/html/rfc7540 14 15 Web Proxy Caches No Caching Example (1) User configures browser: Web accesses via cache Browser sends all HTTP requests to cache Object in cache: cache returns object Else cache requests object from, then returns object to client client client Proxy Assumptions Average object size = 100,000 bits Avg. request rate from institution s browser to s = 15/sec Delay from router to any and back to router = 2 sec Consequences Utilization on LAN = 15% Utilization on access link = 100% Total delay = Internet delay + access delay + LAN delay = 2 sec + minutes + milliseconds network public Internet 1.5 Mbps access link 10 Mbps LAN s 16 17 4

No Caching Example (2) With Caching Example (3) Possible solution Increase bandwidth of access link to, say, 10 Mbps Often a costly upgrade Consequences Utilization on LAN = 15% Utilization on access link = 15% Total delay = Internet delay + access delay + LAN delay = 2 sec + msecs + msecs network public Internet 10 Mbps access link 10 Mbps LAN s Install cache Suppose hit rate is.4 Consequence 40% requests will be satisfied almost immediately (say 10 msec) 60% requests satisfied by Utilization of access link reduced to 60%, resulting in negligible delays Weighted average of delays =.6*2 sec +.4*10msecs < 1.3 secs network public Internet 1.5 Mbps access link 10 Mbps LAN s cache 18 19 HTTP Caching Problems Clients often cache documents Challenge: update of documents If-Modified-Since requests to check HTTP 0.9/1.0 used just date HTTP 1.1 has an opaque entity tag (could be a file signature, etc.) as well When/how often should the al be checked for changes? Check every time? Check each session? Day? Etc? Use Expires header If no Expires, often use Last-Modified as estimate Fraction of HTTP objects that are cacheable is dropping Why? Major exception? This problem will not go away Dynamic data stock prices, scores, web cams CGI scripts results based on passed parameters Other less obvious examples SSL encrypted data is not cacheable Most web clients don t handle mixed pages well many generic objects transferred with SSL Cookies results may be based on past data Hit metering owner wants to measure # of hits for revenue, etc. What will be the end result? 20 21 5

Cookies: Keeping state Cookies: Keeping State Many major Web sites use cookies Four components: 1) Cookie header line in the HTTP response message 2) Cookie header line in HTTP request message 3) Cookie file kept on user s host and managed by user s browser 4) Back-end database at Web site Example: Susan accesses Internet always from the same PC She visits a specific e- commerce site for the first time When initial HTTP requests arrives at the site, the site creates a unique ID and creates an entry in a backend database for that ID Cookie file ebay: 8734 Cookie file amazon: 1678 ebay: 8734 one week later: Cookie file amazon: 1678 ebay: 8734 client usual http request msg usual http response + Set-cookie: 1678 usual http request msg cookie: 1678 usual http response msg usual http request msg cookie: 1678 usual http response msg Amazon creates ID 1678 for user cookiespecific action cookiespecific action 22 23 Overview Content Delivery Overview Content Delivery Web Protocol interactions Caching Cookies Peer-to-peer CDNs Video Web Protocol interactions Caching Cookies Peer-to-peer CDNs Video 24 25 6