移動(dòng)Web客戶端持久化緩存技術(shù)研究
發(fā)布時(shí)間:2018-06-26 10:52
本文選題:移動(dòng)Web + 客戶端緩存; 參考:《華中科技大學(xué)》2013年碩士論文
【摘要】:由于移動(dòng)網(wǎng)絡(luò)帶寬低,延遲高,間歇性連通等缺點(diǎn),Web用戶通過(guò)移動(dòng)網(wǎng)絡(luò)與服務(wù)器交互獲取或提交數(shù)據(jù)時(shí),可能出現(xiàn)響應(yīng)延遲高,甚至網(wǎng)絡(luò)突然中斷導(dǎo)致的Web服務(wù)不可用。客戶端緩存技術(shù)是解決上述問(wèn)題的有效手段,但是傳統(tǒng)的瀏覽器緩存機(jī)制在移動(dòng)網(wǎng)絡(luò)下具有局限性:(1)瀏覽器單向緩存特性不能緩存其提交給服務(wù)器的數(shù)據(jù),斷網(wǎng)提交數(shù)據(jù)丟失,提交操作延遲;(2)驗(yàn)證機(jī)制要求瀏覽器必須獲取服務(wù)器驗(yàn)證結(jié)果才能讀取緩存數(shù)據(jù),網(wǎng)絡(luò)突然中斷將導(dǎo)致緩存數(shù)據(jù)不可用。 結(jié)合移動(dòng)網(wǎng)絡(luò)下Web應(yīng)用的特點(diǎn),提出一種利用HTML5客戶端持久化存儲(chǔ)技術(shù)實(shí)現(xiàn)的Web客戶端持久化緩存方案。所提出的緩存采用HTML5中LocalStorage作為底層的存儲(chǔ)引擎,構(gòu)建一個(gè)雙向緩存,為Web應(yīng)用客戶端提供緩存對(duì)服務(wù)器讀取及提交數(shù)據(jù)的服務(wù),部分解決移動(dòng)網(wǎng)絡(luò)不穩(wěn)定造成的用戶無(wú)法讀取及提交數(shù)據(jù)的問(wèn)題;設(shè)計(jì)一種基于消息機(jī)制的自適應(yīng)一致性同步策略用于緩存數(shù)據(jù)的同步,在盡可能保證數(shù)據(jù)一致性的前提下,分階段提供不同一致性的數(shù)據(jù)窗口,,滿足不同Web應(yīng)用或操作對(duì)數(shù)據(jù)一致性以及響應(yīng)時(shí)間的差異需求。 在實(shí)驗(yàn)室自主研發(fā)論文分享系統(tǒng)中,基于所提出的Web客戶端持久化緩存方案實(shí)現(xiàn)其移動(dòng)客戶端應(yīng)用。對(duì)移動(dòng)客戶端測(cè)試結(jié)果表明,所提出的方案能解決突然斷網(wǎng)的情況下客戶端無(wú)法進(jìn)行數(shù)據(jù)讀取和提交操作問(wèn)題;基于消息機(jī)制的自適應(yīng)一致性同步策略讓應(yīng)用先使用緩存數(shù)據(jù)提供給用戶,待更新到來(lái)時(shí)再更新緩存數(shù)據(jù)提供給用戶;離線操作提交的數(shù)據(jù)先寫入緩存后合并提交到服務(wù)器的策略,相比于運(yùn)用瀏覽器緩存機(jī)制離線無(wú)法提交數(shù)據(jù)待在線重新分次提交的策略,請(qǐng)求次數(shù)由多次合并為單次,消除多次連接造成的時(shí)間開銷,請(qǐng)求數(shù)據(jù)包由多個(gè)合并為單個(gè),消除多個(gè)數(shù)據(jù)包頭造成的帶寬開銷。
[Abstract]:Because of the low bandwidth, high delay, intermittent connectivity and other shortcomings of mobile network, Web users may have high response delay when they interact with the server to obtain or submit data through the mobile network, and even the Web services caused by sudden network interruption may not be available. Client-side caching technology is an effective way to solve the above problems, but the traditional browser caching mechanism has limitations in mobile network: (1) browser one-way caching can not cache the data submitted to the server. (2) the authentication mechanism requires that the browser must obtain the server verification result to read the cached data, and the sudden interruption of the network will cause the cache data to be unavailable. According to the characteristics of Web applications in mobile networks, a Web client persistence cache scheme based on HTML5 client persistence storage technology is proposed. The proposed cache uses Local Storage in HTML5 as the underlying storage engine to construct a bidirectional cache to provide Web application clients with the service of cache reading and submitting data to the server. It partly solves the problem that users can not read and submit data caused by the instability of mobile network, and designs an adaptive consistency synchronization strategy based on message mechanism for cache data synchronization, which can ensure data consistency as much as possible. Different consistent data windows are provided in stages to meet the different requirements of data consistency and response time for different Web applications or operations. In the thesis sharing system, the mobile client application is realized based on the Web client persistent cache scheme. The test results of mobile client show that the proposed scheme can solve the problem that the client can not read and submit data when the network is suddenly cut off. The adaptive consistency synchronization strategy based on message mechanism enables the application to provide the user with cached data first and then update the cache data to the user when the update arrives. The policy that the data submitted offline is written to the cache first and then merged to the server. Compared with the policy that the data can not be submitted online and resubmitted by using the browser caching mechanism, the number of requests is changed from multiple times to a single time. The time cost caused by multiple connections is eliminated, and the request packets are merged into a single packet, and the bandwidth overhead caused by multiple data packet headers is eliminated.
【學(xué)位授予單位】:華中科技大學(xué)
【學(xué)位級(jí)別】:碩士
【學(xué)位授予年份】:2013
【分類號(hào)】:TP333;TP393.09
【參考文獻(xiàn)】
相關(guān)期刊論文 前1條
1 王世克;吳集;金士堯;;Web緩存技術(shù)概述[J];計(jì)算機(jī)與信息技術(shù);2005年06期
本文編號(hào):2070139
本文鏈接:http://sikaile.net/kejilunwen/jisuanjikexuelunwen/2070139.html
最近更新
教材專著