alleviation of stale information in weak cache coherence for

7
SETIT 2005 3 rd International Conference: S ciences of Electronic, Technologies of I nformation and Telecommunications March 27-31, 2005 – TUNISIA Alleviation of Stale Information in Weak Cache Coherence for Wireless WWW Nazrul M. Ahmad * and Ali M. Abdelrahman ** * Faculty of Information Science & Technology, ** Faculty of Engineering & Technology Multimedia University Jalan Ayer Keroh Lama 75450 Melaka Malaysia * [email protected], ** [email protected] Abstract: In this paper, we identify the client polling as a cache coherence mechanism that best satisfies the requirements and improves the performance of web services over wireless networks. However, this mechanism suffers from degradation of client satisfaction by potentially sending stale information. Therefore, we propose a conceptual framework, Multilevel Pre-fetching (MLP), to alleviate the stale information forwarded by the web cache to the clients. The MLP is responsible for improving the level of freshness among the cached objects by pre-fetching the most frequently accessed objects. Key words: Cache Coherence, Pre -fetching, Wireless Networks, World Wide Web 1. Introduction Web caching is deployed to store web objects that are recently fetched from the remote server and make them close to the clients. It provides an opportunity to refine the HyperText Transfer Protocol (HTTP) limitations over wireless networks. The HTTP causes web services to suffer from performance degradation, i.e., it needs excessive number of round trip propagation times between the client and the web server for transferring a document over a low bandwidth. Thus, it significantly increases the file transfer latency. Another factor that limits the capability of HTTP over wireless network is the radio signal dropout, caused by handoff, i.e. the HTTP is a stateless protocol that is unable to resume the file transfer when a connection is broken and re- establis hed. There are several incentives for having caching system in a network. Web caching reduces bandwidth consumption, thereby decreases network traffic and lessens network congestion. It also minimizes access latency by storing frequently accessed documents at nearby caches. Furthermore, it is potentially decreases the workload of the web server. However, there is a side effect whereby the client may receive stale data due to the lack of proper web cache updating. Therefore, cache consistency mechanisms are implemented to ensure that cached copies are frequently updated to keep consistency with the original data. Basically, there are two cache consistency techniques: weak cache consistency and strong cache consistency. According to [1], weak cache consistency is the model in which the access time is significantly reduced, but a stale document might be returned to the client. On the other hand, strong cache consistency enforces the freshness of the document all the time at the expense of extra access for the server resources. Most of the web caches today provide only weak consistency guarantees [1,2]. This mechanism certainly satisfies the static web pages, which change infrequently. But under situations where document modification occurs very frequently or clients have strict requirements on the freshness of the document and the validity of data, such as dynamic web pages, weak cache consistency is unacceptable approach especially for the wireless clients where the freshness of documents is very demanding. Due to this limitation, the strong consistency has to be enforced. However, there is an increase of control messages for sending out “If-Modified-Since” or invalidation messages on the cache-server channel to validate the cached objects. This will significantly introduce high latency of file transfer and degrade the performance of the web cache if most of the cached objects are static page. High latency over wireless network is more

Upload: others

Post on 03-Feb-2022

0 views

Category:

Documents


0 download

TRANSCRIPT

SETIT 2005 3rd International Conference: Sciences of Electronic,

Technologies of Information and Telecommunications March 27-31, 2005 – TUNISIA

Alleviation of Stale Information in Weak Cache Coherence for Wireless WWW Nazrul M. Ahmad *and Ali M. Abdelrahman **

*Faculty of Information Science & Technology, ** Faculty of Engineering & Technology Multimedia University

Jalan Ayer Keroh Lama 75450 Melaka

Malaysia *[email protected], ** [email protected]

Abstract: In this paper, we identify the client polling as a cache coherence mechanism that best satisfies the requirements and improves the performance of web services over wireless networks. However, this mechanism suffers from degradation of client satisfaction by potentially sending stale information. Therefore, we propose a conceptual framework, Multilevel Pre-fetching (MLP), to alleviate the stale information forwarded by the web cache to the clients. The MLP is responsible for improving the level of freshness among the cached objects by pre-fetching the most frequently accessed objects. Key words: Cache Coherence, Pre -fetching, Wireless Networks, World Wide Web

1. Introduction Web caching is deployed to store web objects that

are recently fetched from the remote server and make them close to the clients. It provides an opportunity to refine the HyperText Transfer Protocol (HTTP) limitations over wireless networks. The HTTP causes web services to suffer from performance degradation, i.e., it needs excessive number of round trip propagation times between the client and the web server for transferring a document over a low bandwidth. Thus, it significantly increases the file transfer latency. Another factor that limits the capability of HTTP over wireless network is the radio signal dropout, caused by handoff, i.e. the HTTP is a stateless protocol that is unable to resume the file transfer when a connection is broken and re-establis hed.

There are several incentives for having caching system in a network. Web caching reduces bandwidth consumption, thereby decreases network traffic and lessens network congestion. It also minimizes access latency by storing frequently accessed documents at nearby caches. Furthermore, it is potentially decreases the workload of the web server. However, there is a side effect whereby the client may receive stale data due to the lack of proper web cache updating. Therefore, cache consistency mechanisms are

implemented to ensure that cached copies are frequently updated to keep consistency with the original data.

Basically, there are two cache consistency techniques: weak cache consistency and strong cache consistency. According to [1], weak cache consistency is the model in which the access time is significantly reduced, but a stale document might be returned to the client. On the other hand, strong cache consistency enforces the freshness of the document all the time at the expense of extra access for the server resources.

Most of the web caches today provide only weak consistency guarantees [1,2]. This mechanism certainly satisfies the static web pages, which change infrequently. But under situations where document modification occurs very frequently or clients have strict requirements on the freshness of the document and the validity of data, such as dynamic web pages, weak cache consistency is unacceptable approach especially for the wireless clients where the freshness of documents is very demanding. Due to this limitation, the strong consistency has to be enforced. However, there is an increase of control messages for sending out “If-Modified-Since” or invalidation messages on the cache-server channel to validate the cached objects. This will significantly introduce high latency of file transfer and degrade the performance of the web cache if most of the cached objects are static page. High latency over wireless network is more

SETIT2005

costly to the clients. This is due to the nature of wireless network where the bandwidth is very limited and expensive.

In this study, we have investigated the possibility of deploying weak consistency mechanism for wireless web services. The real challenge here is how the mechanism could be improved to alleviate stale data forwarded to the clients by the web cache. In particular, this paper proposes the framework of improving web cache consistency by introducing Multilevel Pre-fetching.

2. Related Work A considerable amount of work has been done in

the web caching in order to improve its effectiveness (e.g. web cache location, cache routing, dynamic data caching, cache architecture, cache replacement, cache coherence, pre-fetching, etc.). This section reviews the previous work of web caching with the primary emphasis on cache coherence and pre-fetching.

2.1 Cache Coherence Mechanism

Caches provide documents at lower access latency, but sometimes provide clients with stale pages [3]. To prevent stale information from being transferred to the clients, a web cache must ensure that locally cached data is consistent with that stored on the original server. The proper cache coherence mechanism must be employed by the web cache. Most of the existing web caches provide only weak cache consistency [4].

Under Time-To-Live (TTL) approach, each object is assigned a TTL value by origin server, which could be any value that is reasonable to the object itself, or to the content provider. This value is an estimated lifetime of the cached object, after which the object is regarded as invalid. When TTL expires, the next request for the object will be forwarded to the original server. Gwertzman and Seltzer initially used a flat distribution for their simulation, where they assigned all objects with equal TTL values. Experimentally, this resulted in poor performance [4].

Adaptive TTL takes advantage of the fact that file lifetime distribution is not flat. If a file has not been modified for a long time, it tends to stay unchanged. Gwertzman and Seltzer also mentioned that globally popular files are the least likely to change. By using adaptive TTL, the probability of stale documents is kept within reasonable bounds (<5%) [4]. The study did not address other important issues, such as server loads, client response times, and consistency latency.

2.2 Pre-fetching

Previous research has shown that the maximum cache HIT rate can be achieved by any caching algorithm is usually no more than 40 to 50 percent. The reason is simple: most people browse and explore the web, trying to surf new information. One way to further raise the caching HIT ratio is to anticipate

future document requests and pre-fetch these documents in a web cache.

Kroeger et al. investigated the performance limits of pre-fetching between web servers and web caches. He has shown that combining prefect caching and prefect pre-fetching at the web caches can at least reduce the client latency by 60 percent for high bandwidth clients [5].

Markatos and Chronaki [6] assumed that web servers regularly push their most popular documents to the web cache, which then push those documents to the clients. They evaluated the performance of the strategy using several web server traces and found that this technique can anticipate more than 40 percent of a client’s request. The technique requires cooperation from the web servers. The study did not evaluate client latency reduction from the technique.

Gwertzman and Seltzer [7] discussed a technique called Geographical Push-Caching where a Web server selectively sends documents to the caches that are closest to the clients. The focus of the study is on deriving reasonably accurate network topology information to select caches.

Padmanabhan and Mogul [8] analysed the latency reduction and network traffic of pre-fetching using web server traces and trace driven simulation. The prediction algorithm they used is based on the Prediction-by-Partial-Matching (PPM) data compressor with prefix depth of 1. The study has shown that pre-fetching from web servers to individual clients can reduce client latency by 45 percent at the expense of doubling the network traffic.

Crovella and Barford [9] analysed the network effects of pre-fetching. They have proved that pre-fetching can reduce access latency at the cost of increasing network traffic and increasing network traffic burstiness (and thereby increasing network delays). They proposed a rate-controlled pre-fetching scheme to minimize the negative impact on the network by minimising the transmission rate of pre-fetched documents.

3. Overview of Cache Coherence Most of the existing web caches deploy weak

consistency algorithms, where it is possible for the clients to get stale web pages from the caches.

3.1 Common Web Consistency Algorithms

Time-To-Live (TTL) and Client Polling are typical examples for weak cache consistency mechanis ms. TTL-based strategy is simple to implement, each object (document, image file, etc.) is assigned a TTL value. This is an estimated lifetime of an object in the cache. When the TTL expires, the object is considered invalid and accordingly the next request for this invalid object will be forwarded to retrieve it from the original server if it has been modified.

SETIT2005

Table 1. Simulation results based on EPA WWW Web Server trace, NC

Weak Cache Consistency Update Threshold

Parameter

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 GET Requests 16101 16101 16101 16101 16101 16101 16101 16101 16101 Hits 7137 8809 9846 10596 11235 11649 12029 12503 12885 Stale Hits 374 955 1555 2848 5658 5956 7843 8569 10303

Client polling is another approach for weak cache

consistency. In which the cache checks the server periodically to determine the validity of cached objects. Alex FTP cache [10] uses an update threshold to determine how frequent to poll the server. The update threshold is expressed as a percentage of the object’s age. An object is invalidated when the time since the last validation exceeds the update threshold times the object’s age [4]. A request for an invalid object causes the cache to send an “If-Modified-Since” (IMS) control message to the server to retrieve the object if it has been changed. Otherwise, the cache sends the cached object to the client.

TTL and client polling mechanisms assign the essential task to the web cache for providing up-to-date objects. The frequency at which the cache checks the object’s validity can be used to estimate whether the client gets a fresh object or not. The fundamental role of the object lifetime and update threshold is to trade-off between object freshness and network bandwidth.

3.2 Limitations of Weak Consistency

The primary interest of this paper is to develop a cache consistency algorithm for the wireless network. Fortunately, the client polling mechanism offers the best foundation for this purpose, where the lifetime of the cached object is not flat. However, this algorithm has two major drawbacks: firstly, the cache may return a stale copy if the object is changed in the original server while the cached copy is considered valid. Secondly, the cache can invalidate a data copy, which is still valid in the original server. More recently, the negative impacts of the existing mechanisms have been investigated via critical simulations in [11], where the HTTP logs has been captured by replaying the web server trace from Research Triangle Park, North Carolina. It has contained a day’s worth requests to the EPA WWW server. The trace file has generated more than 16000 requests to the web server. In this study, Table 1 presents only significant numbers of stale hits being recorded by cache hits using various update thresholds.

4. Proposed Enhancements The number of stale HITs produced by the client

polling drastically increase as the web cache increments its update threshold. That means, the client tends to receive a lot of stale information if the web cache minimizes the frequency of polling the server.

Thus, some modifications to the algorithm have to be done to reduce the number of stale objects by enhancing the level of freshness among the cached objects. The following subsections elaborate the proposal in details.

4.1 Adoption of Pre-fetching Algorithm

Pre-fetching is a technique to increase the chances of getting the document from the web cache. This work tends to exploit the pre-fetching concept to enhance the consistency mechanism. Pre-fetching could be used to reduce the number of stale documents forwarded to the clients. It is initiated by web cache on the cache-server channel. Documents are pre-fetch because they are out of date or they will become stale in the near future.

Multilevel Pre-fetching (MLP) is proposed in conjunction with the client polling mechanism to refine its drawbacks. The primary objective of MLP is to pre-fetch cached objects which their lifetimes still valid. This is due to the fact that cached objects whose lifetimes don’t expire but they might be modified in their origin server. Thus, there is a possibility for the client to retrieve the stale document mainly because of wrong judgment by the client polling. The MLP is an extension to the client polling mechanism and responsible for validating the cached objects without waiting for requests from the clients.

However, the pre-fetching introduces both new traffic and additional processing to the cache and server. Therefore, a trade off is made between reducing the stale documents and minimizing the cache-server overload. In order to avoid the cache-server overload, the MLP is only executed when the cache-server channel is idle or under utilized.

4.2 Implementation of MLP

Basically, there are two major components added to the conventional weak cache consistency mechanism: Bandwidth Manager (BWM) and Cache Manager (CM). The BWM keeps the records of all active web pages and prepares a list of entries that are recently fetched from the server. Also, it monitors, computes the link utilization and estimates the available bandwidth. Meanwhile, the CM is responsible for pre-fetching and validating the cached objects before they are likely to be requested again by the client, i.e. it maintain freshness of web pages in the cache. Figure 1 shows the enhanced client polling with MLP algorithm architecture.

SETIT2005

Figure 1. Enhanced Client Polling with MLP Algorithm

The MLP will invoke a timer to schedule the

events as follows. After every t sec the BWM initiates the bandwidth information, which contains the percentage of link utilization and the list of page entries. It determines whether the bandwidth is sufficient enough to perform pre-fetching. If the bandwidth is available the BWM forwards the list of entries to the CM for constructing a tree of MLP sub-nodes. Otherwise, the timer should proceed to the next cycle. However, when the timer reaches mt sec and the bandwidth is unavailable the BWM signals the CM to terminate all the existing trees if any.

Upon receipt of a list of entries from the BWM, the CM constructs a tree of multilevel sub-nodes based on the particular list. The CM expects the arrival of the next list of entries at t sec or more, and accordingly it creates a new tree. Thus, there is a possibility of several trees to be run concurrently.

The worst case occurs when the bandwidth is unavailable for an interval of mt sec, where the CM will be instructed by the BWM to terminate all the existing trees. This occurs when the cache-server

channel is congested or fully utilized. By eliminating the trees, the bandwidth is completely reserved for normal operation. Once the bandwidth is available again the pre-fetching process will resume. The construction of multilevel sub-nodes is described in the following section.

4.3 Maintaining Pre-Fetching List Of Entries

Every cached object is to be assigned with the page lifetime by BWM. Figure 2 illustrates the relationship between the cached object’s age and the access frequency. Cached object’s age is defined as:

Cached Object Age = t0 × n × exp (X)

where t0 is the initial age assigned to the cached object, n is the access frequency and

X=[( current_time – entry_time) / current_time]

BWM saves the following information of the cached objects: object id (page_id), access frequency (n) and the time when a web cache stores the object at the first entry (entry_time). If the object is accessed

SETIT2005

more frequently by the client, the age of the object will be allocated with a longer period of expiry. Each time the object being accessed, new object lifetime will be imposed.

Figure 2. Cached Object Lifetime

Figure 3 shows the expiration checking by the BWM in order to prepare the list of entries. As described earlier, every t sec or validated time, the BWM will prepare the list of entries based on the existing cached objects. Validated time is the time when a BWM confirms the validity of the cached object. If the object’s age is still valid the BWM assigns the page_id of the cached object into the list of entries. But if the object’s age is expired the object will be drop from the list and to be re-considered again in the next cycle. After validating all the cached objects, the BWM forwards the list of entries to CM for pre-fetching.

Example: Consider two cached objects, Page_A and Page_B, whose entry_time is day 1 and day 15 respectively. The initial age assigns to those objects is assumed to be 2 days. At day 20, both cached objects are being accessed again by the clients. Therefore, the BWM will immediately impose new age to those objects. That means, Page_A will be marked as valid for next 10 days and Page_B for the next 5 days. Now

let us assume that after the six days have elapsed, the BWM is ready to prepare the list of entries for CM. If the object’s age is still valid (e.g. Page_B), BWM assigns the particular object to the list of entries as shown in Figure 3.

4.4 Construction of Multilevel Sub-Nodes

Once the CM receives a list of entries from the BWM, the first sub-node is generated and assigned with a random index number from the entries. For instance, as shown in Figure 4, the sub-node A is created at level L1 of the first tree T1 and assigned with a random index number Z which lies between 0 and y, where y is the total number of entries in the list. This index number corresponds to the page_id of the cached object. Similarly, the second sub-node B is generated at level L2 and assigned with any index number within the range from 0 to Z. This process is repeated throughout the list to build a logical tree of multilevel sub-nodes.

Meanwhile, the CM can start creates another tree whenever it receives a new list of entries. Figure 5 illustrates the construction of second tree T2 after the next cycle when the second list of entries arrives at CM. Every sub-node is responsible for searching the corresponding object in the web cache to check its lifetime.

If the object is still valid it will be pre-fetched from the remote server. Otherwise, the sub-node will be terminated immediately. In the pre-fetching process, the CM issues an IMS control message to the remote server to check the validity of the cached objects. If the content has changed the web server will send a new copy of that particular document to the web cache. Now, the web cache is capable to provide a fresh document if it is requested by the client. If the content remains unchanged the web server will send a Reply 304 message to notify the CM. Then, the respective sub-node will be terminated. The same process is repeated till the last node of the tree. On the other hand, if the bandwidth is unavailable for a certain interval of mt sec the BWM will signal the CM to terminate all the existing trees as shown in Figure 6.

Figure 3. Cached Object Validity Checking by BWM

1 t0

Access Frequency, n

Obj

ect’s

age

SETIT2005

Figure 4. Construction of Multilevel Sub-nodes

5. Conclusions This paper addresses the problems of implementing

weak cache consistency algorithms over wireless network. Then proposes an alternative by highlighting the key design objectives and outlining the novel framework of weak cache consistency algorithm with multilevel pre -fetching. The multilevel pre -fetching is responsible for validating cached objects without waiting for the requests from the clients. It is executed whenever the cache-server link is under utilised. By doing this, the cache object is always consistent with the data in the original server. Thus introduction of multilevel pre -fetching will significantly increase the level of freshness among the cache objects, which in turn results in less number of stale objects that could be forwarded to the clients.

The simulation tool has been enhanced with the multilevel pre -fetching in conjunction with the weak cache consistency algorithm. The primary test of the proposed architecture has been successfully carried out, while an intensive performance evaluation is on progress.

Figure 5. Creation of T2 in Concurrent with T1

Figure 6. Termination of All Trees

Page_03

Page_78

Page_77 Page_80 Page_09

.

.

.

.

.

Page_90 Page_23 Page_78

null null

Page_01

2 1 0

.

. Z

.

.

.

.

.

y

null null null

n

Index, n Page -id

Tree, T1

A

C B

G F E D

L1

L2

L3

0

A

B C

D E F G

Z1

Z y

Z2

Z3 Z4 Z5 Z6

L1

L2

L3

SETIT2005

References [1] P. Cao and C. Liu, Maintaining Strong Cache Consistency in the World Wide Web, Proceedings of the 17th International Conference on Distributed Computing Systems (ICDCS’97), Baltimore, May 1997, pp. 12-21

[2] V. Duvvuri, Adaptive Leases: A Strong Consistency Mechanism for the World Wide Web, Master’s thesis, University of Massachusetts, June 1999.

[3] J. Wang, A Survey of Web Caching Schemes for the Internet, ACM SIGCOMM Computer Communication Review, vol. 27, no. 5, ACM Press, Oct. 2001, pp. 36-46.

[4] J. Gwertzman and M. Seltzer, “World-Wide Web Cache Consistency,” In Proceedings of the 1996 USENIX Technical Conference, San Diego, CA, January 1996, pp. 141-152

[5] T. M. Kroeger, D. D. E. Long and J. C. Mogul, Exploring the Bounds of Web Latency Reduction from Caching and Pre-fetching, Proceedings of the 1997 USENIX Symposium on Internet Technologies and Systems, Monterey, CA, Dec. 1997.

[6] E. P. Markatos, C. E. Chronaki, A TOP-10 approach to pre-fetching on Web, Proceedings of INET’98

[7] J. Gwertzman, M. Seltzer, The Case for Geographical Pushing-Caching, HotOS Conference, 1994 (ftp://das-ftp.harvadr.edn/techreports/tr-34-94.ps.gz)

[8] V. N. Padmanabhan, J. C. Mogul, Using Predictive Pre-fetching to Improve World Wide Web Latency, Proceedings of Sigcomm’96.

[9] M. Crovella, P. Batford, The Network Effects of Pre -fetching, Proceedings of Infocom’98

[10] V. Cate, Alex – A global file system, in Proc. of the USENIX File System Workshop, Ann Arbor, MI, pp. 1-11, 1992.

[11] Nazrul M. Ahmad and Ali M. Abdelrahman, Performance of Web Cache Consistency Algorithms over Wireless Networks, 6th MMU International Symposium on Information and Communications Technologies 2003, Malaysia, 2003