Method, terminal and system for updating caches

An update method and terminal technology, applied in the transmission system, electrical components, etc., can solve the problems of inability to update data synchronously on the background server, low update efficiency, poor control of time granularity, etc., and achieve the effect of improving data processing performance

Active Publication Date: 2014-12-17
TENCENT TECH (SHENZHEN) CO LTD
View PDF6 Cites 8 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] During the research and practice of the existing technology, the inventor found that the existing technology has at least the following problems: Html5's local storage technology localStorage will not eliminate and update cached data by itself, and the storage space is limited
Although the standard Http cache can automatically eliminate the cache by setting the cache timeout time, the time granularity is not easy to control, and the setting is too large or too small to meet the actual needs; although you can add the If-Modify-Since header to the request to get the latest Data, but each request needs to be verified, and a network connection needs to be initiated, resulting in low update efficiency
The above two solutions are only to solve the storage problem, and cannot effectively update the data synchronously with the background server, and cannot guarantee the correctness of the cached data at a small cost

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method, terminal and system for updating caches
  • Method, terminal and system for updating caches
  • Method, terminal and system for updating caches

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0045] In order to make the technical problems solved by the present invention, the technical solutions adopted and the technical effects achieved clearer, the technical solutions of the embodiments of the present invention will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only the technical solutions of the present invention. Some, but not all, embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative efforts fall within the protection scope of the present invention.

[0046] Please refer to figure 1 , which is a method flowchart of the first embodiment of the cache update method of the embodiment of the present invention. This embodiment is mainly applied to terminals capable of running Web applications, including smart phones, e-book readers, MP3 (Moving Picture Experts Group Audio Layer III, moving picture expert...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a method, a terminal and a system for updating caches. The method for updating the caches includes starting Web application programs, recording starting time of the Web application programs, receiving application download requests of the Web application programs, acquiring timestamps in AJAX [asynchronous JavaScript and XML (extensive markup language)] cache data if the AJAX cache data corresponding to the application download requests are available locally, judging whether the starting time is later than or identical to the timestamps or not, and omitting updating of the AJAX cache data if the starting time is later than or identical to the timestamps; transmitting AJAX cache data verification requests to background servers corresponding to the application download requests if the starting time is not later than or identical to the timestamps, and updating the AJAX cache data according to return data of the background servers. Issue time of the background servers is recorded by the timestamps. According to the technical scheme, the method, the terminal and the system have the advantages that only the cache data which are downloaded before the Web application programs are started need to be verified, the cache data which are downloaded after the Web application programs are started do not need to be verified, and accordingly the correctness of the cache data can be guaranteed at a low cost.

Description

technical field [0001] The invention relates to the technical field of web page development, in particular to a cache update method, terminal and system. Background technique [0002] AJAX refers to Asynchronous JavaScript and XML (asynchronous JavaScript and XML), AJAX is a technology for creating interactive web applications. Through AJAX, JavaScript can use JavaScript's XMLHttpRequest object to communicate directly with the server. Through this object, JavaScript can exchange data with the Web server without reloading the page. [0003] The existing standard Http cache and Html5's local storage technology localStorage can both be used to provide data for offline applications when the network is disconnected. [0004] During the research and practice of the prior art, the inventor found at least the following problems in the prior art: the local storage technology localStorage of Html5 cannot eliminate and update cached data by itself, and the storage space is limited. A...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): H04L29/08
Inventor 龙海建
Owner TENCENT TECH (SHENZHEN) CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products