Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Method and device for refreshing cached data

A caching data and caching technology, applied in database update, structured data retrieval, etc., can solve problems such as increasing system complexity, reducing overall system maintainability and stability, increasing dependence, etc., to reduce thread data consumption and ensure maintenance Performance and scalability, and the effect of reducing request time

Active Publication Date: 2019-06-11
ADVANCED NEW TECH CO LTD
View PDF5 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0007] However, in the lock-based approach, the lock has a certain system overhead, which will increase the complexity of the system; the asynchronous task-based approach relies on additional software components or services, adding additional dependencies and reducing the maintenance of the overall system performance and stability, there is additional system overhead, and it will also increase the complexity of the system

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 and device for refreshing cached data
  • Method and device for refreshing cached data
  • Method and device for refreshing cached data

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0086] In order to make the above objects, features and advantages of the present application more obvious and comprehensible, the present application will be further described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0087] Methods based on in-program synchronization locks (distributed locks are used in distributed environments) or other similar external exclusive mechanisms such as database row-level locks can specifically include the following methods:

[0088] 1. Blocking lock; the operation steps can be as follows:

[0089] a. The cache read thread finds that the cache data needs to be refreshed;

[0090] b. Request to acquire a lock;

[0091] c. If the acquisition of the lock fails, it will block and wait;

[0092] d. If the lock is acquired successfully, check again whether the cached data needs to be refreshed (secondary confirmation, avoiding that the previous cached reading thread has completed the refresh...

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

Embodiments of the invention provide a cached data refreshing method and apparatus. The method comprises the steps of receiving a query request for cached data in a cached database, wherein the cached data has hard failure time; judging whether the cached data meets a preset old data condition or not; and when the old data condition is met, randomly refreshing the cached data according to the hard failure time and current time. According to the embodiments of the invention, one or a few requests are randomly screened out from query requests of numerous cached data to perform refreshing operation, so that excessively great impact on a back-end system is avoided while the cached data is refreshed.

Description

technical field [0001] The present application relates to the technical field of caching, in particular to a method for refreshing cached data and a device for refreshing cached data. Background technique [0002] With the development of information technology and network technology, most applications will use caching technology for performance considerations. Generally, some commonly used original data will be read and cached from data sources such as configuration files when the system is started, so as to improve the read performance. Access performance for data with more writes and less data. [0003] If the original data is modified or expired, the cached data needs to be refreshed. In the case of cached data for accessing hotspots, if a large number of front-end requests find that a certain cached data needs to be refreshed at the same time, they will rush to the back-end system (such as a database) to obtain the latest data at the same time, causing a huge instantane...

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 Patents(China)
IPC IPC(8): G06F16/23
Inventor 张广铃
Owner ADVANCED NEW TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products