HTTP 2019/20 COMP3322B Modern Technologies on WWW
Contents • HTTP • Request & Response • Proxy • Cookies • Quick Practice 2
Core Features of the Web 1. A URL to uniquely identify a resource on the WWW. 2. At two ends, there are two programs interacting by means of the HTTP protocol , which is one form of client-server communication . • The browser program which makes HTTP requests from URLs and that can display the HTML it receives. • The web server software program that responds to HTTP requests. 3. The HTTP protocol to describe how requests and responses operate. 4. HTML and CSS to publish documents. 3
HyperText Transfer Protocol (H T T P) • HTTP is the foundation of data communication for the WWW. • It is an application layer protocol that is sent over TCP . • The protocol specifies format and meaning of messages exchanged between clients and servers. • Each message has control information and message content presented in plaintext format , but it supports transmission of arbitrary binary data. • Can download or upload data. 4
HyperText Transfer Protocol (H T T P) • It follows a classical client-server communication model: • The client (a web browser) first initiates a TCP connection to the Web server. • After that, it sends a request to the connected server. • Then it waits for the response from the server. connect accept HTTP request HTTP response Browser Web Server 5
Stateless Protocol • HTTP is a stateless protocol. • This means that • each request is independent • the system does not have memory to store the relationship between two requests • every request is considered as a new request without knowledge of previous activities . • Server does not maintain information about the access history of the clients. • In the past, all web pages were static pages; this makes error recovery really simple. • This creates difficulty for users attempting to interact with certain pages coherently, for example, using e-commerce shopping carts. 6
Evolution of HTTP • HTTP/0.9 – 1991 • HTTP/1.0 – 1996 • HTTP/1.1 – 1997 • HTTP/2 – 2015 • HTTP/3 is coming 7
HTTP/1.0 • HTTP/0.9 was called the one-line protocol and only supported one type of request: the GET request. • HTTP headers were introduced in HTTP/1.0 • New functionality can even be introduced by adding a new header. • Made it easy to extend and experiment with new features. • Added the status code info in the response messages. • HTTP/1.0 has one major issue: • A new TCP connection is opened for each request/response exchange. • This affects the communication performance. connect accept request 1 response 1 Browser Web Server connect accept request 2 response 2 8
HTTP/1.1 • HTTP/1.1 is still widely used at the moment. • To improve performance: • It introduced the concept of reusing the TCP connection (aka Persistent Connection ) for multiple request/response exchanges.
You've reached the end of your free preview.
Want to read all 33 pages?
- Fall '13
- World Wide Web, Web server, Web browser, Hypertext Transfer Protocol