2.2 Flashcards
What is important about HTTP?
Hyptertext transfer protocool
web’s application model
client browser requests, receives and displays web objects
web server sends objects in response to requests
both occur using HTTP protocol
What connection protocol does HTTP use and how is it done?
Client initiates TCP connection (creates socket) to server, port 80
server accepts TCP connection from client
HTTP messages exchanged between browser and Web server
Important things about Non-Persistent HTTP
at most one object is sent over TCP connection before its closed thus multiple objects require multiple connection
issues:
Requires to RTTs per object
OS overhead for each TCP connection
browsers often open parallel TCP connection to fetch referenced objects
What is an RTT? How does it relate to Non-Persitent HTTP
RTT: time for a small packet to travel from client to server and back
non-persistent HTTP response time = One RTT to initiate TCP connection +
one RTT for HTTP request + first few bytes of HTTP response to return +
file transmission time
Important things about persistent HTTP
connection stays open
client sends requests as soon as it encounters referenced object
little as one RTT for all the referenced objects
difference between HTTP 1.0 and 1.1
- 0 has get post and head methods
1. 1 has get post head, put and delete
What are the 4 components of cookies?
cookie header line of HTTP response
cooke header line in next HTTP request message
cookie file kept on user’s host, managed by user browser
back-end database at web site
What can cookies be used for?
authorization
shopping carts
recommendations
user session state(webmail)
Whats a web cache and why are they useful?
why?
reduces traffic on an instructions access link
reduce response time for client request
what?
local web cache basically acts as both a client and server to retrieve frequently requested objects quickly
to optimize can use conditional get to only retrieve object if cache doesn’t have most up to date version