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

Data caching method, device, equipment and storage medium

A technology of data caching and caching nodes, which is applied in the computer field, can solve problems such as the complexity of data caching and backup work, and achieve the effects of reducing complexity, improving security capabilities, and increasing storage capacity

Active Publication Date: 2022-02-22
WUHAN DOUYU NETWORK TECH CO LTD
View PDF7 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] The embodiment of the present invention provides a data caching method, device, equipment and storage medium, which solves the technical problem that the backup work of the existing data caching is relatively complicated

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
  • Data caching method, device, equipment and storage medium
  • Data caching method, device, equipment and storage medium
  • Data caching method, device, equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0053] figure 1 It is a flow chart of the data caching method provided by Embodiment 1 of the present invention. The technical solution of this embodiment is applicable to the situation where the client or proxy sends cached data to the server. The method can be executed by the data caching device provided in the embodiment of the present invention. The device can be implemented in the form of software and / or hardware, and configured to be applied in a processor of the client or the agent.

[0054] The method specifically includes the following steps:

[0055] S101. Obtain a write request for cached data, and determine a hash slot corresponding to the cached data according to the write request.

[0056] The write request for cached data can be a write request for cached data input by the client received by the client, or a write request for the client to automatically read the cached data generated by the application, or a cached data sent to it by the client obtained by the a...

Embodiment 2

[0066] figure 2 It is a flow chart of the data caching method provided by Embodiment 2 of the present invention. On the basis of the above-mentioned embodiments, the embodiment of the present invention adds the steps of the method for detecting the working status of the cache node. Such as figure 2 As shown, the method includes:

[0067] S104. Detect the working state of each cache node based on a preset detection sequence.

[0068] In order to ensure the validity and real-time performance of the data cache, it is usually necessary to make the cache nodes (servers) that provide the cache service in a normal working state. For this reason, the client or agent in this embodiment detects each cache node based on the preset detection order working status. It is understandable that the client or agent can also detect the working status of each cache node in real time, as long as the device performance of the client or agent can ensure the real-time performance of data cache, ...

Embodiment 3

[0079] image 3 is a schematic structural diagram of the data cache device provided in Embodiment 3 of the present invention. The device is used to execute the data caching method provided in any of the above embodiments, and the control device may be implemented by software or hardware, and configured for use on a client or an agent. Such as image 3 As shown, the device includes:

[0080] A write request acquisition module 11, configured to acquire a write request for cached data, and determine a hash slot corresponding to the cached data according to the write request;

[0081] Correspondence acquisition module 12, configured to acquire a correspondence between a hash slot and a cache node, and determine a cache node corresponding to the hash slot according to the correspondence, wherein the cache node is provided with a corresponding slave node ;

[0082] The sending module 13 is configured to send the cached data to the cache node corresponding to the hash slot, and t...

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 embodiment of the present invention discloses a data caching method, device, device, and storage medium, wherein the data caching method includes: obtaining a write request for cached data, and determining a hash slot corresponding to the cached data according to the write request; obtaining The corresponding relationship between the hash slot and the cache node, according to the corresponding relationship to determine the cache node corresponding to the hash slot, wherein the cache node is provided with a corresponding slave node; the cache data is sent to the The cache node corresponding to the hash slot, and the cache data is synchronized from the cache node to the slave node corresponding to the cache node. It solves the technical problem of complex data cache backup work in the prior art, reduces the complexity of data backup, ensures the security of cache data stored in cache nodes, and does not greatly increase the storage of cache data in other working nodes It is beneficial to ensure that other cache nodes are always in good working condition.

Description

technical field [0001] The embodiments of the present invention relate to the field of computer technology, and in particular, to a data caching method, device, equipment, and storage medium. Background technique [0002] For most caching scenarios, only a key-value store that supports multiple reads and multiple writes is required. Existing mainstream server caching solutions include master-slave mode (Master-slave) and X-Cluster cluster. The Master-slave scheme appeared earlier and is suitable for scenarios with more reads and fewer writes, but not for scenarios with more reads and more writes. X-Cluster is the officially recommended cluster solution. It is decentralized and its performance scales linearly with the increase of nodes. Although it is suitable for scenarios with multiple reads and multiple writes, the deployment is relatively complicated. Moreover, these two data caching schemes are more complicated in terms of data backup, which makes the reliability of da...

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): H04L67/568H04L67/1095
CPCH04L67/1095H04L67/568
Inventor 李奇张文明陈少杰
Owner WUHAN DOUYU NETWORK 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