Steps on accessing a web site

Slides:



Advertisements
Similar presentations
Enabling Secure Internet Access with ISA Server
Advertisements

TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 22 World Wide Web and HTTP.
1 Caching in HTTP Representation and Management of Data on the Internet.
EEC-484/584 Computer Networks Lecture 6 Wenbing Zhao
Web Caching Schemes1 A Survey of Web Caching Schemes for the Internet Jia Wang.
Internet Networking Spring 2006 Tutorial 12 Web Caching Protocols ICP, CARP.
The Internet Useful Definitions and Concepts About the Internet.
EEC-484/584 Computer Networks Discussion Session for HTTP and DNS Wenbing Zhao
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 Spring Semester 2007, Dept. of Computer Science, Technion Internet Networking recitation #13 Web Caching Protocols ICP, CARP.
Internet Networking Spring 2002 Tutorial 13 Web Caching Protocols ICP, CARP.
Application Layer  We will learn about protocols by examining popular application-level protocols  HTTP  FTP  SMTP / POP3 / IMAP  Focus on client-server.
Caching and Content Distribution Networks. Web Caching r As an example, we use the web to illustrate caching and other related issues browser Web Proxy.
Web Proxy Server Anagh Pathak Jesus Cervantes Henry Tjhen Luis Luna.
Web Cache. Introduction what is web cache?  Introducing proxy servers at certain points in the network that serve in caching Web documents for faster.
COMPUTER TERMS PART 1. COOKIE A cookie is a small amount of data generated by a website and saved by your web browser. Its purpose is to remember information.
Networking Components Chad Benedict – LTEC
FIREWALL TECHNOLOGIES Tahani al jehani. Firewall benefits  A firewall functions as a choke point – all traffic in and out must pass through this single.
1 CMSCD1011 Introduction to Computer Audio Lecture 10: Streaming audio for Internet transmission Dr David England School of Computing and Mathematical.
Packet Filtering. 2 Objectives Describe packets and packet filtering Explain the approaches to packet filtering Recommend specific filtering rules.
1 3 Web Proxies Web Protocols and Practice. 2 Topics Web Protocols and Practice WEB PROXIES  Web Proxy Definition  Three of the Most Common Intermediaries.
1 Computer Communication & Networks Lecture 28 Application Layer: HTTP & WWW p Waleed Ejaz
XHTML Introductory1 Linking and Publishing Basic Web Pages Chapter 3.
CH2 System models.
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.
HTTP evolution - TCP/IP issues Lecture 4 CM David De Roure
Implementing ISA Server Caching
NETWORKING FUNDAMENTALS. Network+ Guide to Networks, 4e2.
Web Design and Development. World Wide Web  World Wide Web (WWW or W3), collection of globally distributed text and multimedia documents and files 
Internet Applications (Cont’d) Basic Internet Applications – World Wide Web (WWW) Browser Architecture Static Documents Dynamic Documents Active Documents.
09/13/04 CDA 6506 Network Architecture and Client/Server Computing Peer-to-Peer Computing and Content Distribution Networks by Zornitza Genova Prodanoff.
Overview on Web Caching COSC 513 Class Presentation Instructor: Prof. M. Anvari Student name: Wei Wei ID:
Search Engine and Optimization 1. Introduction to Web Search Engines 2.
Welcome to 711. Welcome to 711. Xinfeng Ye Room: Office hours: whenever I am around or me for appointment 1.
E-Business Infrastructure PRESENTED BY IKA NOVITA DEWI, MCS.
4.01 How Web Pages Work.
Web fundamentals: Clients, Servers, and Communication
Block 5: An application layer protocol: HTTP
How HTTP Works Made by Manish Kushwaha.
WWW and HTTP King Fahd University of Petroleum & Minerals
Content Distribution Networks
Web Development Web Servers.
Caching Temporary storage of frequently accessed data (duplicating original data stored somewhere else) Reduces access time/latency for clients Reduces.
Introduction To Web Design
Practical Censorship Evasion Leveraging Content Delivery Networks
E-commerce | WWW World Wide Web - Concepts
Host of Troubles : Multiple Host Ambiguities in HTTP Implementations
Hypertext Transport Protocol
E-commerce | WWW World Wide Web - Concepts
Web Caching? Web Caching:.
Cache Memory Presentation I
Switching Techniques In large networks there might be multiple paths linking sender and receiver. Information may be switched as it travels through various.
Utilization of Azure CDN for the large file distribution
Internet Networking recitation #12
Internet Applications
CS222 Web Programming Course Outline
Computer Communication & Networks
1 Introduction to the Internet.
Distributed Systems CS
ACT102 Introduction to web design
Web Design & Development
CSE 461 HTTP and the Web.
ACT102 Introduction to web design
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 4: Planning and Configuring Routing and Switching.
Switching Techniques.
HyperText Transfer Protocol
EE 122: HyperText Transfer Protocol (HTTP)
EE 122: Lecture 22 (Overlay Networks)
4.01 How Web Pages Work.
Presentation transcript:

Steps on accessing a web site

The time for the client to set up a TCP connection with the web server The time for DNS server to resolve the web server’s name to IP address (if necessary). Not shown in the diagram The time for the client to set up a TCP connection with the web server The time for the request transmitted from the client to the web server The time for the web server to parse the request and generate a web page The time for the response transmitted from the host to client The time when all the information are received by the client The time for the client browser to render the page

How to reduce the response time Reduce the network latency (i.e. transmission delay) Place servers closer to the clients Could be significant Reduce the amount of information that have to be sent to the clients Benefits the users that connect to the servers through low-bandwidth networks For a given bandwidth, less information to be transmitted means less time is needed for transmission Reduce the load on the web server Generate the response faster How to achieve these? Proxy server, caching server A proxy server normally caches web contents. But, web contents can be cached on other types of servers as well.

Web Cache A web cache usually sits between the web server and clients Watches requests come by, and saves copies of the responses for them. When there is a coming request for the same URL resource, the web cache can retrieve the cached response and send it back to the client without asking for the web server to serve this request again.

Advantages of Web Caching Reducing network latency There is a distance between clients and web servers. Caching web object locally can dramatically reduce transmitting latency

Reducing bandwidth consumption Cache the web objects close to the client side Reponses to the same requests do not need to be transferred again between the proxy server that caches the web objects and the origin web server. Reducing server load Some of the requests do not need to be handled by the origin server. As some requests can be served from proxy servers, the origin web server can direct more capability to deal with other requests. Improve the response time for the non-cached contents.

Categories of Web Caching Browser Many web browsers support caching. When a web page is first requested, the browser saves the web page in the disk. If the page is requested again or the user clicks the “Back” button, the cached page might be used. In some cases, the browser might need to check with the remote web server to see whether the cached page is still valid. If it is valid, the page in the local disk is used. Examples: Firefox, IE.

Proxy Server There are two types of proxy servers, i.e. forward proxy and reverse proxy A forward proxy is an intermediate system that enables a browser to connect to a remote network to which it normally does not have access. A forward proxy can also be used to cache data, reducing load on the networks between the forward proxy and the remote web server. A reverse proxy (http accelerator) is installed in front of web servers. All connections coming from the Internet addressed to one of the web servers are routed through the proxy server, which may either deal with the request itself or pass the request to the web server behind.

Proxy servers are located in various locations throughout the Web. hierarchical caching structure Each cache serves many clients, which may be users or other caches. When the request is not served by a local cache, the request is passed on to a higher level in the hierarchy, until reaching a root cache, which, having no parent, would request the object from the origin server.

cooperative caching architecture Caches communicate with each other as peers (e.g., using an inter-cache protocol). On a miss, a cache would ask a predetermined set of peers whether they already have the missing object. If so, the request would be routed to the first responding cache. Otherwise, the cache attempts to retrieve the object directly from the origin server. This approach can prevent storage of multiple copies and reduce origin server retrievals Suffers from increased inter-cache communication. Instead of asking peers directly about each request, a peer periodically gives peers a summary of the contents of the cache

Content Delivery/Distribution Network (CDN) CDN is designed to place content caching servers at the edge of network around the world. It reduces the traffic congestion on the network and the latency perceived by users. The caching servers at the edge side of network are called edge servers which can cache HTML pages, images, audio and video files. Examples: Akamai, Digital Island

The forward proxy then decides which edge server to communicate with. When the client requests a web page, the request is firstly sent to a forward proxy. The forward proxy then decides which edge server to communicate with. If none of the edge servers cache this page, the request is delivered to the web server. Otherwise, one of the edge servers , which is closest to the client, will serve the request. Examples: Akamai EdgeSuite, IBM WebSphere Edge Server

Potential problems The end user see stale (e.g., old or out-of-date) content, compared to what is available on the origin server (i.e., fresh content). HTTP does not ensure strong consistency Caching tends to improve the response times only for cached responses that are subsequently requested (i.e., hits). Misses that are processed by a cache generally have decreased speed. Thus, a cache only benefits requests for content already stored in it. Caching is limited by a high rate of change of source data. Some responses cannot or should not be cached Web server will set and send the HTTP headers that determine cacheability

Dynamic Data Page Dynamic data pages are generated by applications according to the underlying frequently changing data sources such as databases and files. Dynamic data pages are usually generated on the demand of user’s request. Dynamic pages have two characteristics: high volatility and high variation It is volatile because not only it changes more frequently but also its change is unpredictable. It is various because it is often customized or personalized from a set of content fragments. Compared to a static page, a dynamic data page is expensive to create. more valuable to cache a dynamic data page

Proxy-based Dynamic Page Caching Proxy-based caching approaches can be classified into three broad categories page-level caching fragment-level caching data-centric caching In the page-level caching , the proxy server caches full-page outputs. Many commercial products have applied this approach. Compared to no-caching, the page-level caching has the following advantages: reduce the page generation delay reduce the delay associated with packet filtering and other firewall-related delays reduce the bandwidth required to transmit the content from the web server to the proxy

The page-level caching has the following limitations There is often very little reusability of full HTML pages A personalised page displaying the name of the user at the top of the page: the cached page in the proxy is only reusable if the same user accesses to the same page Unnecessary invalidation If there is only one element of the page becomes invalid, then the whole page needs to be invalidated in the cache.

Fragment-level caching Fragment-level caching requires establishing a template for each dynamically generated page. The template file specifies the contents and layout of the page. Essentially, each page is factored into a number of fragments of differing cacheability profiles and different caching expiration time. The fragments and the templates of the pages are maintained as separate elements on the origin servers and the proxy servers. A web page is assembled at proxy caching server when the page is requested. Popularized by Akamai as part of the Edge Side Includes (ESI) initiative

Edge Side Includes (ESI) Edge Side Includes (ESI) is a simple markup language used to define web page fragments of differing cacheability profiles and different caching expiration time. ESI defines some tags that can be used in the template files. A template file is a normal HTML file with ESI tags. Amongst the ESI tags, “esi: include” is used to include a fragment.

<html> <body> <esi:include src=http://example.com/advertise.jsp /> <esi:include src=http://example.com/navigation.jsp /> <esi:include src=http://example.com/personalize.jsp /> <esi:include src=http://example.com/news.jsp /> </body> </html> advertise navigation personalize news

Fragment-level caching need the developer to partition the pages. Compared with page-level caching approach, fragment-level caching approach can improve hit rates as it can specify granular caching capability. According to the properties of different fragments, the fragment can be set with different caching expiring time and cacheability. Fragment-level caching need the developer to partition the pages. Might require the re-writing of pages or applications Further reading http://www.esi.org/

Data-centric caching Fragment-level caching requires the web pages to be factored into a number of fragments Data-centric caching focuses on the contents of the data being transmitted. Carried out by the underlying mechanism. Does not require the cooperation of the web page authors We will look at two schemes: Value-Based Web Caching S. C. Rhea, K. Liang and E. Brewer, Value-Based Web Caching, Proc. of the 12th International Conference on World Wide Web, pp. 619 – 628, 2003 Delta encoding Jeffrey C. Mogul, Fred Douglis, Anja Feldmann, Balachander Krishnamurthy, Potential benefits of delta encoding and data compression for HTTP, 1997

Value-Based Web Caching A lot of information being transmitted over the Internet are redundant, since they are identical. 25-30% text-based responses were caused by resource modifications. Many modifications only change the contents of the information being transmitted by a small amount. Aliasing, which means two distinct URIs reference the same data, also results in redundant data being transmitted over the network. Aliased data account for 36% of the data transferred Value-based web caching exploits similarities between data to eliminate redundant data transmission caused by resource modification and aliasing

Message Digest (hash) Used to represent a message with a given number of bits. produced by condensing the information in the message MD5 Produce a 128-bit digest.

The cached blocks are indexed using their fingerprints. A page is broken into blocks of approximately 2KB each, and each block is named by its fingerprint (i.e. digest) calculated using a secure hash function MD5. According to the properties of MD5, it is highly unlikely that two blocks containing different contents have the same fingerprint. Two blocks are regarded as identical if their fingerprints are the same. The cached blocks are indexed using their fingerprints. If the responses to two requests contain identical blocks, the identical blocks do not need to be sent again in the second response.

The scheme was proposed to reduce the latency of the users connecting to the Internet through low-speed connection.

The scheme uses two kinds of proxies. One resides on the user’s PC, called child proxy; The other one resides on the user’s ISP, called parent proxy. The child proxy caches the contents of the blocks and their fingerprints. The parent proxy only records the fingerprints of the blocks that are cached on the child proxy. The origin server is responsible for partitioning pages into blocks and computing the fingerprints. When a parent proxy receives the blocks that constitute the response to a user’s request, the parent proxy determines which blocks the child proxy already has by checking the fingerprints of the received blocks. The parent proxy only sends the blocks that the child proxy does not have to the child proxy. The child proxy assembles the page according to the received/cached blocks and delivers the page to the user.

Instead of using a fixed block size, e. g Instead of using a fixed block size, e.g. 2KB per block, the scheme uses Rabin functions to determine how to partition a page into blocks. The benefit of this approach is that modifications to a page would only affect the block(s) in which the modifications occur.

Determine the boundary according to the value of the blocks. Let f be a function mapping n one-byte inputs uniformly and randomly to the set {0, …, 2047}. Place a block boundary before byte i in a resource if the value of f on the n bytes proceeding byte i is 0. Since f is uniform and random, we expect to evaluate it on average 2048 times before finding a zero; thus the expected block size from this technique is 2 kB.

Delta encoding In delta encoding, the origin server generates many different “base files”. When a user’s request arrives, the server finds the base file that is closest to the response to be sent back to the user. The difference (“delta”) between the response and the chosen base file is computed. Then, the delta and a reference to the base file are sent back to the user. The bandwidth savings stem from the fact that the base file is commonly used and the user has a local copy of the base file. Thus, the user can obtain the requested page by applying the delta to the base file.

V1, replace “cancelled” with “on” server request 734 exam is cancelled. V1 client V1 revalidate 734 exam is not cancelled. V2 V1, replace “cancelled” with “on” 734 exam is on. V3

Review What are the main steps in accessing a web applications? What measures can be used to reduce the response time of a web-based application? What is the techniques for implementing these measures? What does a web cache work? What does a web cache do to reduce the response time to web applications? Assume that (a) two clients access a web application through two connections with different network latencies, and, (b) the difference in network latency for the two connection is x ms. Explain why the difference in response time to the two clients might be significantly higher than x ms.

Review How do the forward proxy and reverse proxy work? Understand how web caches are placed on the Internet and how they are used. How does a CDN work? What are the problems associated with the use of web cache? What are dynamic pages and what are the features of the dynamic pages? Understand how page-level caching and fragment-level caching work and the potential problems associated with them. What are the two observations on the network traffic that justify the use of value-based web caching?

Review How does the value-based web caching technique work? What are the potential problems that associated with the value-based caching? How does delta encoding based web caching scheme work? Compare with other web caching techniques, what are the strength and the weakness of the scheme?