Unlock instant, AI-driven research and patent intelligence for your innovation.

A data caching method

A data cache and data technology, applied in the field of network communication, can solve the problems of random IO reading ability, random reading and writing ability limitation, etc., and achieve the effects of reducing occupation, realizing separation, and improving storage capacity

Active Publication Date: 2016-06-22
ULTRAPOWER SOFTWARE
View PDF3 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0002] With the increase in the number of users of instant messaging products and the increase in user activity, the number of friends in instant messaging products has grown exponentially, and the pressure on the system for data access is bound to increase, and a large number of concurrent random accesses to the database are usually It is the bottleneck of the system, because it is a very random access for users to obtain relevant data of all their friends, and the random IO read ability of the database to the disk is limited by the random read and write ability of the disk itself

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
  • A data caching method
  • A data caching method
  • A data caching method

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0038] The core idea of ​​the present invention is: serialize the data put into the cache, reduce the occupied memory, cache as much data as possible, and adopt a new cache management method to realize the separation of hot and cold data, avoiding the Random access makes hot data obsolete.

[0039] In addition, after the data is cached, because the memory cache is lost after the service starts abnormally, a large number of business accesses will "penetrate" the cache to directly access the database.

[0040] In this regard, the present invention further periodically persists the cached hot data to the disk to form a dmp file, and then records the update of the cache into a log (log) file. If the service restarts, use the dmp file to restore the hot zone data in the cache, read the log file (recording the modification of the cache after persistence), and delete the corresponding modification record in the log file from the restored cache, that is The correctness of the cache c...

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 data cache method. The method includes: serializing the data put into the cache; dividing the cache into two areas, called a cold area and a hot area, both of which adopt a doubly linked list structure; when inserting data into the cache, first Put the data in the cold area; when the data in the cache is hit, if the data is cold area data, judge whether the data has hit the preset number of times, and if so, transfer it to the end of the hot area, otherwise transfer it To the head of the cold zone linked list, if the data is hot zone data, transfer it to the head of the hot zone linked list. The technical scheme of the invention effectively improves the caching efficiency of hot data.

Description

technical field [0001] The invention relates to the technical field of network communication, in particular to a data caching method. Background technique [0002] With the increase in the number of users of instant messaging products and the increase in user activity, the number of friends in instant messaging products has grown exponentially, and the pressure on the system for data access is bound to increase, and a large number of concurrent random accesses to the database are usually It is the bottleneck of the system, because it is a very random access for users to obtain relevant data of all their friends, and the random IO read ability of the database to the disk is limited by the random read and write ability of the disk itself. [0003] Therefore, only by finding a way to determine hot data and caching as much hot data as possible (hot data refers to data that has been accessed more times, it can also be called active data, relatively, inactive data is called cold d...

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): G06F12/0802G06F3/06G06F17/30
Inventor 王洪泽
Owner ULTRAPOWER SOFTWARE