CN112115167B - Cache system hot spot data access method, device, equipment and storage medium - Google Patents

Cache system hot spot data access method, device, equipment and storage medium Download PDF

Info

Publication number
CN112115167B
CN112115167B CN202010850146.0A CN202010850146A CN112115167B CN 112115167 B CN112115167 B CN 112115167B CN 202010850146 A CN202010850146 A CN 202010850146A CN 112115167 B CN112115167 B CN 112115167B
Authority
CN
China
Prior art keywords
data
candidate
accessed
access
fragment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010850146.0A
Other languages
Chinese (zh)
Other versions
CN112115167A (en
Inventor
段涛
王帆
罗岳
陈冬
余文华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suning Cloud Computing Co Ltd
Original Assignee
Suning Cloud Computing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suning Cloud Computing Co Ltd filed Critical Suning Cloud Computing Co Ltd
Priority to CN202010850146.0A priority Critical patent/CN112115167B/en
Publication of CN112115167A publication Critical patent/CN112115167A/en
Priority to CA3128540A priority patent/CA3128540C/en
Application granted granted Critical
Publication of CN112115167B publication Critical patent/CN112115167B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24552Database cache management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/061Improving I/O performance
    • G06F3/0611Improving I/O performance in relation to response time
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0655Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
    • G06F3/0656Data buffering arrangements
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Databases & Information Systems (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

The application relates to a cache system hot spot data access method, a cache system hot spot data access device, computer equipment and a storage medium. The method comprises the following steps: receiving an access request of a cache system, wherein the access request carries an identifier of data to be accessed; when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule; and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed. By adopting the method, the flow of the fragments where the hot keys are located can be dispersed, so that the uniform access of the hot keys is realized, and the access efficiency of the cache system is improved.

Description

Cache system hot spot data access method, device, equipment and storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for accessing hot spot data in a cache system, a computer device, and a storage medium.
Background
Redis is a distributed K-V (Key-value Key value pair) cache system widely used by current enterprises, when the system is accessed, a fragment is calculated according to a hash (hash function) of a Key to access the K-V, however, in practical application, a large number of keys (possibly corresponding to a certain promotion commodity, hot news, hot comments and the like) are requested in some peak periods, the Key can be called as a hot Key, and according to the hash of the hot Key, all access requests fall into the same fragment, the load of the fragment is seriously aggravated, so that the response time of the fragment is too long, and the access efficiency is low.
Disclosure of Invention
Based on this, it is necessary to provide a method, an apparatus, a computer device and a storage medium for accessing hot spot data of a cache system, which are capable of dispersing traffic of segments where hot spot keys are located, thereby achieving uniform access of the hot spot keys and improving access efficiency of the cache system.
A cache system hotspot data access method comprises the following steps:
receiving an access request of a cache system, wherein the access request carries a data identifier to be accessed;
when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule;
and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier.
In one embodiment, before receiving the cache system access request, the method includes: acquiring candidate hot spot data, wherein the candidate hot spot data comprises a corresponding candidate hot spot data identifier; acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment to enable the candidate fragment to load candidate hot spot data; and generating a candidate hot spot data list according to the candidate hot spot data.
In one embodiment, the cache system hot spot data access method further includes: acquiring preset failure time corresponding to each candidate hotspot data; and when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
In one embodiment, after receiving the cache system access request, the method further includes: acquiring a preset counter; responding to the access request through a preset counter, and acquiring the current access times corresponding to the data identification to be accessed; when the current access times do not reach the access times threshold value, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list or not; and when determining that the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list, entering a step of acquiring a preset routing scheduling rule.
In one embodiment, the cache system hot spot data access method further includes: when the current access times reach an access times threshold value, acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment, and loading data to be accessed through each candidate fragment; acquiring a current counting state corresponding to a preset counter; and setting the current counting state as the current failure state, and determining that the preset counter does not count any more.
In one embodiment, when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hotspot data list, the method includes: acquiring a candidate hotspot data list, wherein the candidate hotspot data list comprises each candidate hotspot data, and each candidate hotspot data comprises a corresponding candidate hotspot data identifier; and when the candidate hot spot data identification identical to the to-be-accessed data identification exists, determining that the to-be-accessed data corresponding to the to-be-accessed data identification is in the candidate hot spot data list.
In one embodiment, the cache system hot spot data access method further includes: when the data to be accessed corresponding to the data identification to be accessed is not in the candidate hotspot data list, determining a corresponding default fragment according to the data identification to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identification to be accessed; and responding to the access request through the default fragment, and acquiring an access result corresponding to the data identifier to be accessed.
A cache system hotspot data access device, the device comprising:
the access request receiving module is used for receiving an access request of the cache system, and the access request carries the identifier of the data to be accessed;
the routing rule obtaining module is used for obtaining a preset routing scheduling rule when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hotspot data list;
and the access result generation module is used for routing the access request to the target fragment according to a preset routing scheduling rule, responding the access request through the target fragment and acquiring an access result corresponding to the identifier of the data to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the identifier of the data to be accessed.
A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the following steps when executing the computer program:
receiving an access request of a cache system, wherein the access request carries an identifier of data to be accessed;
when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule;
and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed.
A computer-readable storage medium, on which a computer program is stored which, when executed by a processor, carries out the steps of:
receiving an access request of a cache system, wherein the access request carries an identifier of data to be accessed;
when the data to be accessed corresponding to the data identification to be accessed is in the candidate hot spot data list, acquiring a preset routing scheduling rule;
and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed.
The cache system hot spot data access method, the cache system hot spot data access device, the computer equipment and the storage medium receive a cache system access request, wherein the access request carries an identifier of data to be accessed; when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule; and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier. Therefore, the target segment may be specially used for processing access requests corresponding to other access data identifiers, and the access data corresponding to the other access data identifiers may not be the hot data, so that the access request corresponding to the hot data may be routed to the segment corresponding to the non-hot data through the routing scheduling rule, and the traffic of the segment corresponding to the hot data is shared by the segment corresponding to the non-hot data, thereby achieving uniform access to the hot data.
Drawings
FIG. 1 is a diagram of an application environment of a cache system hotspot data access method in one embodiment;
FIG. 2 is a flowchart illustrating a hot spot data access method of a cache system according to an embodiment;
FIG. 3 is a flowchart illustrating a hot spot data access method of a cache system according to an embodiment;
FIG. 4 is a schematic flowchart of a hot spot data access method of a cache system in another embodiment;
FIG. 5 is a flowchart illustrating a hot spot data access method of a cache system according to an embodiment;
FIG. 6 is a flowchart illustrating a hot spot data access method of the cache system in one embodiment;
FIG. 7 is a flowchart illustrating the matching of candidate hot spot data lists in one embodiment;
FIG. 8 is a flowchart illustrating a method for accessing hot spot data in a cache system in accordance with an embodiment;
FIG. 9 is a block diagram of an embodiment of a cache system hot spot data access device;
FIG. 10 is a diagram of the internal structure of a computer device in one embodiment;
FIG. 11 is a diagram illustrating an internal structure of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more clearly understood, the present application is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
The cache system hotspot data access method provided by the application can be applied to the application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The terminal 102 may be, but not limited to, various personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices, and the server 104 may be implemented by an independent server or a server cluster formed by a plurality of servers.
Specifically, the terminal 102 obtains a cache system access request, where the access request carries an identifier of data to be accessed, and sends the access request to the server 104 through network connection, and after receiving the cache system access request, the server 104 obtains a preset routing scheduling rule when the data to be accessed corresponding to the identifier of the data to be accessed is in a candidate hotspot data list, and routes the access request to a target fragment according to the preset routing scheduling rule, and responds to the access request through the target fragment, and obtains an access result corresponding to the identifier of the data to be accessed, where the target fragment is not a fragment specially used for processing the access request corresponding to the identifier of the data to be accessed.
In another embodiment, the server 104 receives an access request of the cache system, where the access request carries an identifier of data to be accessed, and when the data to be accessed corresponding to the identifier of the data to be accessed is in the candidate hotspot data list, obtains a preset routing scheduling rule, routes the access request to a target fragment according to the preset routing scheduling rule, and responds to the access request through the target fragment to obtain an access result corresponding to the identifier of the data to be accessed, where the target fragment is not a fragment specially used for processing the access request corresponding to the identifier of the data to be accessed.
In an embodiment, as shown in fig. 2, a cache system hot spot data access method is provided, which is described by taking the method as an example applied to the terminal or the server in fig. 1, and includes the following steps:
step 202, receiving an access request of the cache system, wherein the access request carries an identifier of data to be accessed.
The cache system (Redis) is a distributed K-V (key-value key value pair) cache system widely used by an enterprise at present, in the distributed system, the cache plays an important role and serves as a hotspot cache or a full-volume cache, and in the process of using the cache, a plurality of fragments are usually used, so that the cache capacity can be increased, the pressure of a server where the cache system is located can be dispersed, and better capacity support is provided for the service of the cache system.
The cache system access request is used for requesting access to the cache system, and may be generated by performing operation triggering through an access control provided by the relevant service access application, where the operation may be, but is not limited to, a click operation, a voice operation, a timing event, and the like. The access request carries a data identifier to be accessed, the data identifier to be accessed is used for uniquely identifying data to be accessed, and a corresponding access result can be determined according to the data identifier to be accessed.
And 204, when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule.
In practical applications, during some peak hours, a large number of requests frequently access the same data, for example, access the same key, where the key may correspond to a certain promotional product, hot news, hot reviews, etc. of an application, and these requests may be instantaneously concentrated on a certain slice, thereby affecting the request response time of the slice, and for those slices where the access requests have less data, the flow of cache requests may be less.
Therefore, after the access request is received, whether the data to be accessed corresponding to the data identification to be accessed carried by the access request is the hotspot data or not can be judged, if the data is the hotspot data, the access request corresponding to the hotspot data can be dispersed into each fragment for access in order to avoid response failure caused by a large number of requests of the access request, and therefore uniform access to the hotspot data is achieved.
Specifically, after an access request of a cache system is received, a candidate hotspot data list can be obtained, where the candidate hotspot data list includes at least one candidate hotspot data, and the candidate hotspot data list is matched with the candidate hotspot data list, so that whether the data to be accessed corresponding to the data identifier to be accessed in the access request is hotspot data can be determined, and if the data to be accessed corresponding to the data identifier to be accessed is in the candidate hotspot data list, it indicates that the data to be accessed is hotspot data, uniform access needs to be performed on the data to be accessed, and a preset routing scheduling rule is obtained, where the preset routing scheduling rule is a routing scheduling rule preset for uniform access on the hotspot data, and can be determined in advance according to a service requirement, an actual application scenario, or a product requirement.
In another embodiment, if the data to be accessed corresponding to the data identifier to be accessed is not in the candidate hotspot data list, it indicates that the data to be accessed is not hotspot data, and there is not so much capacity, and the access request of this time can be processed through the default fragment corresponding to the data identifier to be accessed, so that the matched default fragment is determined according to the data identifier to be accessed, and the access request is responded through the default fragment, and a corresponding access result is obtained. The default shards are specially used for processing the access requests corresponding to the data identifiers to be accessed, and the access requests corresponding to different access data identifiers can be processed by different default shards.
And step 206, routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier.
The target fragment is used for processing the fragment of the access request through a preset routing scheduling rule, that is, the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed, the target fragment can be a fragment specially used for processing access requests corresponding to other access data identifiers, and the access data corresponding to the other access data identifiers may not be hot data.
Specifically, after the preset routing scheduling rule is obtained, the access request may be routed to the target fragment according to the preset routing scheduling rule, where the target fragment may be preloaded with each piece of hot data, and when the access request corresponding to the identifier of the data to be accessed is routed to the target fragment, the target fragment directly responds to the access request, thereby obtaining an access result corresponding to the identifier of the data to be accessed.
In another embodiment, the target segment does not pre-load each hotspot data, but records the access times of the access requests corresponding to the same data identifier to be accessed through a preset timer, when the access times reach a preset access time threshold, each hotspot data can be loaded through the target segment, after the target segment finishes the loading of the hotspot data, the access request corresponding to the data identifier to be accessed can be routed to the target segment according to a preset routing scheduling rule, and the target segment directly responds to the access request, thereby obtaining the access result corresponding to the data identifier to be accessed.
When the access times do not reach a preset access time threshold value, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hot spot data list, and when determining that the data to be accessed corresponding to the data identification to be accessed is in the candidate hot spot data list, entering the step of obtaining a preset routing scheduling rule.
In a specific embodiment, it is assumed that a certain distributed system has 10 sets of candidate fragments (1-10), a certain hot-spot key is only routed to the candidate fragment 1 according to a default HASH rule, if 10000 of candidate fragments concurrently access the hot-spot key, the instantaneous access amount of the candidate fragment 1 is 10000, by the cache system hot-spot access method of the present application, the hot-spot key is temporarily loaded on all 10 sets of candidate fragments, and when 10000 of candidate fragments concurrently access the hot-spot key, the concurrent requests are dispersed to 10 sets of candidate fragments according to a preset routing scheduling rule, the access amount of each set of candidate fragments is only 1000, so that the candidate fragments only bear the original 1/10 of traffic.
In the cache system hotspot data access method, a cache system access request is received, wherein the access request carries an identifier of data to be accessed; when the data to be accessed corresponding to the data identification to be accessed is in the candidate hot spot data list, acquiring a preset routing scheduling rule; and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed. Therefore, the target segment may be specially used for processing access requests corresponding to other access data identifiers, and the access data corresponding to the other access data identifiers may not be the hot data, so that the access request corresponding to the hot data may be routed to the segment corresponding to the non-hot data through the routing scheduling rule, and the traffic of the segment corresponding to the hot data is shared by the segment corresponding to the non-hot data, thereby achieving uniform access to the hot data.
In one embodiment, as shown in fig. 3, before receiving the cache system access request, the method includes:
step 302, candidate hotspot data are obtained, and the candidate hotspot data comprise corresponding candidate hotspot data identifiers.
Step 304, a candidate fragment set is obtained, and the candidate fragment set comprises at least one candidate fragment.
And step 306, traversing each candidate segment to enable the candidate segment to load the candidate hot spot data.
And 308, generating a candidate hot spot data list according to the candidate hot spot data.
Before receiving an access request of a cache system, all candidate fragments can acquire all candidate hotspot data, then all candidate hotspot data are loaded in advance, the candidate hotspot data which are loaded successfully form a candidate hotspot data list, when the access request of the cache system is received, whether the data to be accessed corresponding to the data identification to be accessed carried by the access request is in the candidate hotspot data list or not is judged, if yes, a target fragment can be determined from the candidate fragments according to a preset routing scheduling rule, the access request is responded through the target fragment, and a corresponding access result is obtained.
Specifically, candidate hotspot data are obtained, where the candidate hotspot data include corresponding candidate hotspot data identifiers, where the candidate hotspot data may be obtained specifically by determining from a large number of web crawlers, data crawlers, or access records of various hot websites, and the candidate hotspot data include corresponding candidate hotspot data identifiers, and different candidate hotspot data correspond to different candidate hotspot data identifiers.
Further, all candidate fragments are obtained, all candidate fragments form a candidate fragment set, all candidate fragments are traversed, all candidate fragments load the candidate hot spot data once, and when each candidate fragment successfully loads the candidate hot spot data, a candidate hot spot data list is formed by the candidate hot spot data, namely the candidate hot spot data are added into the candidate hot spot data list.
In one embodiment, as shown in fig. 4, the cache system hot spot data access method further includes:
step 402, acquiring preset failure time corresponding to each candidate hotspot data.
And step 404, when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
When each candidate fragment loads candidate hotspot data, the preset failure time corresponding to the candidate hotspot data needs to be set, and the preset failure time is not very long under normal conditions, so that the peak access period can be set. The preset failure time corresponding to each candidate hotspot data can be determined according to business requirements, actual application scenes, product requirements and the like, and the preset failure time corresponding to each candidate hotspot data can be the same or different. In order to waste resources, when the preset failure time is reached, removing the candidate hotspot data corresponding to the preset failure time from the candidate hotspot data list, updating the candidate hotspot data list, and obtaining the updated candidate hotspot data list.
In a specific embodiment, before the cache system accesses, hot spots keys are collected in advance, all candidate fragments are circularly traversed, each candidate fragment loads the hot spots keys once, and meanwhile, the failure time is set, so that the failure time is not long under the general condition, and the peak access time can be reached. When the scheduler completes the loading action, the hotspot keys are updated to the candidate hotspot data list.
Further, when the cache system access is performed, the service system needs to access the hotspot key to obtain the preset routing scheduling rule. Since the hotspot key is loaded in advance and the candidate hotspot data list is updated, the access request is routed to other target fragments by adopting preset routing scheduling rules such as random, polling or least recently used. When the hotspot key fails, the candidate hotspot data list also removes the hotspot key.
In one embodiment, as shown in fig. 5, after receiving the cache system access request, the method further includes:
step 502, acquiring a preset counter.
And 504, responding to the access request through a preset counter, and acquiring the current access times corresponding to the data identifier to be accessed.
Step 506, when the current access times do not reach the access times threshold, determining whether the data to be accessed corresponding to the data identifier to be accessed is in the candidate hotspot data list.
Step 508, when it is determined that the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, the step of obtaining a preset routing scheduling rule is started.
If each candidate fragment does not pre-load each hot spot data before receiving the access request of the cache system, each candidate fragment completes the loading of the hot spot data again when the access amount of a certain hot spot data is increased and a certain preset threshold value is triggered. Specifically, a preset counter is obtained, where the preset counter is used to record access times of the hot spot data, for example, the preset counter is used to record access times of an access request corresponding to the identifier of the data to be accessed, and the preset counter is used to respond to the access request to obtain current access times corresponding to the identifier of the data to be accessed.
Further, it is determined whether the data to be accessed corresponding to the data identifier to be accessed triggers a certain preset threshold, specifically, an access frequency threshold is obtained, it is determined whether the data to be accessed triggers the preset threshold according to the access frequency threshold and the current access frequency, if the current access frequency does not reach the access frequency threshold, it is indicated that the access volume of the data to be accessed does not reach the preset threshold, and there is no large access volume, it is determined whether the data to be accessed corresponding to the data identifier to be accessed is in the candidate hotspot data list, and if it is determined that the data to be accessed corresponding to the data identifier to be accessed is in the candidate hotspot data list, the step of obtaining the preset routing scheduling rule is performed.
In one embodiment, as shown in fig. 6, the cache system hotspot data access method further includes:
step 602, when the current access frequency reaches the access frequency threshold, acquiring a candidate slice set, where the candidate slice set includes at least one candidate slice.
And step 604, traversing each candidate fragment, and loading the data to be accessed through each candidate fragment.
Step 606, obtaining a current counting state corresponding to a preset counter.
Step 608, the current counting state is set to the current failure state, and it is determined that the preset counter does not count any more.
If the current access times reach the access time threshold, it is indicated that the access amount of the data to be accessed reaches a preset threshold, and the access amount is large, therefore, all candidate fragments are obtained, all candidate fragments form a candidate fragment set, all candidate fragments are traversed, each candidate fragment loads the data to be accessed once, and simultaneously, a current counting state corresponding to a preset counter is obtained, when each candidate fragment successfully loads the data to be accessed, the current counting state is set to be a current failure state, when the preset counter set to be the current failure state does not count any more, the counting operation is stopped.
In a particular embodiment, the hotspot keys are not loaded in advance prior to caching system accesses. When the cache system is accessed, the hotspot key needs to be accessed, and since the candidate hotspot data list does not have the hotspot key at this time, the request is routed to the matched candidate segment 1 according to the hotspot key, and the candidate segment 1 is specially used for processing the hotspot key. And when the preset counter reaches or exceeds a preset threshold value, the counter triggers all candidate fragments to complete the dynamic loading of the hot KEY.
After the dynamic loading of the hotspot KEY is completed, a counter of the hotspot KEY is set to be invalid and is not counted any more, the hotspot KEY is added into a candidate hotspot data list, and the candidate hotspot data list is updated at the moment, so that the hotspot KEY is routed to a target fragment by adopting preset routing rules such as random, polling or least recently used.
In one embodiment, as shown in fig. 7, when the data to be accessed identifies that the corresponding data to be accessed is in the candidate hotspot data list, the method includes:
step 702, a candidate hotspot data list is obtained, where the candidate hotspot data list includes each candidate hotspot data, and each candidate hotspot data includes a corresponding candidate hotspot data identifier.
Step 704, when there is a candidate hotspot data identifier that is the same as the data identifier to be accessed, determining that the data to be accessed corresponding to the data identifier to be accessed is in the candidate hotspot data list.
The method comprises the steps of identifying data to be accessed by a candidate hotspot data list, judging whether the data to be accessed is hotspot data or not according to whether the data to be accessed corresponding to the data to be accessed is in the candidate hotspot data list or not, and if the data to be accessed is the hotspot data, in order to avoid response failure caused by a large number of requests of access requests, distributing the access requests corresponding to the hotspot data to each fragment for access, thereby realizing uniform access to the hotspot data.
Specifically, after an access request of the cache system is received, a candidate hot spot data list can be obtained, the candidate hot spot data list includes at least one candidate hot spot data, and by matching with the candidate hot spot data list, it can be determined whether the data to be accessed corresponding to the data identifier to be accessed in the access request is the hot spot data, and if the data to be accessed corresponding to the data identifier to be accessed is in the candidate hot spot data list, it indicates that the data to be accessed is the hot spot data, and the data to be accessed needs to be uniformly accessed.
The method comprises the steps of determining whether data to be accessed is in a candidate hot spot data list according to whether a candidate hot spot data identifier is the same as a data identifier to be accessed or not, if so, indicating that the candidate hot spot data identifier which is the same as the data identifier to be accessed exists in the candidate hot spot data list, and determining that the data to be accessed corresponding to the data identifier to be accessed is in the candidate hot spot data list, indicating that the data to be accessed corresponding to the data identifier to be accessed is hot spot data, so that the data to be accessed needs to be uniformly accessed in order to avoid access failure.
In one embodiment, as shown in fig. 8, the cache system hotspot data access method further includes:
step 802, when the data to be accessed corresponding to the data identifier to be accessed is not in the candidate hotspot data list, determining a corresponding default fragment according to the data identifier to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identifier to be accessed.
And step 804, responding to the access request through the default fragment, and acquiring an access result corresponding to the data identifier to be accessed.
Specifically, if the data to be accessed corresponding to the data identifier to be accessed is not in the candidate hot spot data list, it is indicated that the data to be accessed is not hot spot data, and the capacity is not so large, and the access request can be processed through the default fragment corresponding to the data identifier to be accessed, so that the matched default fragment is determined according to the data identifier to be accessed, and the access request is responded through the default fragment, and a corresponding access result is obtained. The default shards are specially used for processing the access requests corresponding to the data identifiers to be accessed, and the access requests corresponding to different access data identifiers can be processed by different default shards.
In a specific embodiment, a method for accessing hot spot data of a cache system is provided, which specifically includes the following steps:
1. and acquiring candidate hotspot data, wherein the candidate hotspot data comprises a corresponding candidate hotspot data identifier.
2. And acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment.
3. And traversing each candidate fragment to enable the candidate fragment to load the candidate hot spot data.
4. And generating a candidate hot spot data list according to the candidate hot spot data.
5. And acquiring preset failure time corresponding to each candidate hotspot data.
6. And when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
7. And receiving an access request of the cache system, wherein the access request carries the identifier of the data to be accessed.
8. And acquiring a preset counter.
9. And responding to the access request through a preset counter, and acquiring the current access times corresponding to the data identification to be accessed.
10. And when the current access times do not reach the access times threshold, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list.
11. And when the data to be accessed corresponding to the data identification to be accessed is determined to be in the candidate hot spot data list, acquiring a preset routing scheduling rule.
11-1, acquiring a candidate hot spot data list, wherein the candidate hot spot data list comprises each candidate hot spot data, and each candidate hot spot data comprises a corresponding candidate hot spot data identifier.
11-2, when a candidate hot spot data identifier identical to the to-be-accessed data identifier exists, determining that the to-be-accessed data corresponding to the to-be-accessed data identifier is in a candidate hot spot data list.
12. And routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed.
13. And when the current access times reach an access time threshold, acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment.
14. And traversing each candidate fragment, and loading the data to be accessed through each candidate fragment.
15. And acquiring the current counting state corresponding to the preset counter.
16. And setting the current counting state as the current failure state, and determining that the preset counter does not count any more.
17. And when the data to be accessed corresponding to the data identifier to be accessed is not in the candidate hotspot data list, determining a corresponding default fragment according to the data identifier to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identifier to be accessed.
18. And responding to the access request through the default fragment, and acquiring an access result corresponding to the data identifier to be accessed.
It should be understood that, although the steps in the above-described flowcharts are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a portion of the steps in the above-described flowcharts may include multiple sub-steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of performing the sub-steps or the stages is not necessarily sequential, but may be performed alternately or alternatingly with other steps or at least a portion of the sub-steps or stages of other steps.
In one embodiment, as shown in fig. 9, a cache system hot spot data access apparatus 900 is provided, which includes: an access request receiving module 902, a routing rule obtaining module 904, and an access result generating module 906, wherein:
an access request receiving module 902, configured to receive an access request of a cache system, where the access request carries an identifier of data to be accessed.
A routing rule obtaining module 904, configured to obtain a preset routing scheduling rule when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hotspot data list.
An access result generating module 906, configured to route the access request to a target fragment according to a preset routing scheduling rule, and respond to the access request through the target fragment to obtain an access result corresponding to the identifier of the data to be accessed, where the target fragment is not a fragment that is specially used to process the access request corresponding to the identifier of the data to be accessed.
In an embodiment, the cache system hot spot data accessing device 900 is further configured to obtain candidate hot spot data, where the candidate hot spot data includes a corresponding candidate hot spot data identifier, obtain a candidate segment set, where the candidate segment set includes at least one candidate segment, traverse each candidate segment, so that the candidate segment loads the candidate hot spot data, and generate a candidate hot spot data list according to the candidate hot spot data.
In an embodiment, the cache system hot spot data access device 900 is further configured to obtain a preset expiration time corresponding to each candidate hot spot data, and when the preset expiration time is reached, remove the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
In an embodiment, the cache system hot spot data access apparatus 900 is further configured to obtain a preset counter, respond to the access request through the preset counter, obtain current access times corresponding to the to-be-accessed data identifier, determine, when the current access times do not reach an access time threshold, whether the to-be-accessed data corresponding to the to-be-accessed data identifier is in the candidate hot spot data list, and enter a step of obtaining a preset routing scheduling rule when determining that the to-be-accessed data corresponding to the to-be-accessed data identifier is in the candidate hot spot data list.
In an embodiment, the cache system hot spot data accessing apparatus 900 is further configured to, when the current access frequency reaches the access frequency threshold, obtain a candidate fragment set, where the candidate fragment set includes at least one candidate fragment, traverse each candidate fragment, load data to be accessed through each candidate fragment, obtain a current counting state corresponding to the preset counter, set the current counting state to be a current failure state, and determine that the preset counter is no longer counting.
In an embodiment, the routing rule obtaining module 904 is further configured to obtain a candidate hot spot data list, where the candidate hot spot data list includes each candidate hot spot data, and each candidate hot spot data includes a corresponding candidate hot spot data identifier, and when there is a candidate hot spot data identifier that is the same as the to-be-accessed data identifier, it is determined that the to-be-accessed data corresponding to the to-be-accessed data identifier is in the candidate hot spot data list.
In an embodiment, the cache system hot spot data accessing apparatus 900 is further configured to determine a corresponding default fragment according to the identifier of the data to be accessed when the data to be accessed corresponding to the identifier of the data to be accessed is not in the candidate hot spot data list, where the default fragment is a fragment that is specially used for processing an access request corresponding to the identifier of the data to be accessed, and respond to the access request through the default fragment to obtain an access result corresponding to the identifier of the data to be accessed.
For specific limitations of the cache system hot spot data access device, reference may be made to the above limitations on the cache system hot spot data access method, which is not described herein again. All or part of each module in the cache system hot spot data access device can be realized by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as shown in fig. 10. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing a candidate hotspot data list. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a cache system hotspot data access method.
In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as shown in fig. 11. The computer device includes a processor, a memory, a network interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a cache system hotspot data access method. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the computer equipment, an external keyboard, a touch pad or a mouse and the like.
Those skilled in the art will appreciate that the configurations shown in fig. 10 or 11 are merely block diagrams of some configurations relevant to the present disclosure, and do not constitute a limitation on the computing devices to which the present disclosure may be applied, and that a particular computing device may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the following steps when executing the computer program: receiving an access request of a cache system, wherein the access request carries a data identifier to be accessed; when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule; and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the data identifier to be accessed, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the data identifier to be accessed.
In one embodiment, the processor, when executing the computer program, further performs the steps of: acquiring candidate hotspot data, wherein the candidate hotspot data comprise corresponding candidate hotspot data identifiers; acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment to enable the candidate fragment to load candidate hot spot data; and generating a candidate hot spot data list according to the candidate hot spot data.
In one embodiment, the processor, when executing the computer program, further performs the steps of: acquiring preset failure time corresponding to each candidate hotspot data; and when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
In one embodiment, the processor when executing the computer program further performs the steps of: acquiring a preset counter; responding to the access request through a preset counter, and acquiring the current access times corresponding to the data identification to be accessed; when the current access times do not reach the access times threshold value, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list or not; and when determining that the data to be accessed corresponding to the data identification to be accessed is in the candidate hot spot data list, entering a step of acquiring a preset routing scheduling rule.
In one embodiment, the processor, when executing the computer program, further performs the steps of: when the current access times reach an access times threshold value, acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment, and loading data to be accessed through each candidate fragment; acquiring a current counting state corresponding to a preset counter; and setting the current counting state as the current failure state, and determining that the preset counter does not count any more.
In one embodiment, the processor when executing the computer program further performs the steps of: acquiring a candidate hotspot data list, wherein the candidate hotspot data list comprises each candidate hotspot data, and each candidate hotspot data comprises a corresponding candidate hotspot data identifier; and when the candidate hotspot data identification identical to the to-be-accessed data identification exists, determining that the to-be-accessed data corresponding to the to-be-accessed data identification is in the candidate hotspot data list.
In one embodiment, the processor when executing the computer program further performs the steps of: when the data to be accessed corresponding to the data identification to be accessed is not in the candidate hotspot data list, determining a corresponding default fragment according to the data identification to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identification to be accessed; and responding to the access request through the default fragment, and acquiring an access result corresponding to the data identifier to be accessed.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when executed by a processor, performs the steps of: receiving an access request of a cache system, wherein the access request carries an identifier of data to be accessed; when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list, acquiring a preset routing scheduling rule; and routing the access request to a target fragment according to a preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier.
In one embodiment, the processor when executing the computer program further performs the steps of: acquiring candidate hotspot data, wherein the candidate hotspot data comprise corresponding candidate hotspot data identifiers; acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment to enable the candidate fragment to load candidate hot spot data; and generating a candidate hot spot data list according to the candidate hot spot data.
In one embodiment, the processor, when executing the computer program, further performs the steps of: acquiring preset failure time corresponding to each candidate hotspot data; and when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
In one embodiment, the processor, when executing the computer program, further performs the steps of: acquiring a preset counter; responding to the access request through a preset counter, and acquiring the current access times corresponding to the data identification to be accessed; when the current access times do not reach the access times threshold value, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list or not; and when determining that the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list, entering a step of acquiring a preset routing scheduling rule.
In one embodiment, the processor, when executing the computer program, further performs the steps of: when the current access times reach an access times threshold value, acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment; traversing each candidate fragment, and loading data to be accessed through each candidate fragment; acquiring a current counting state corresponding to a preset counter; and setting the current counting state as the current failure state, and determining that the preset counter does not count any more.
In one embodiment, the processor when executing the computer program further performs the steps of: acquiring a candidate hotspot data list, wherein the candidate hotspot data list comprises each candidate hotspot data, and each candidate hotspot data comprises a corresponding candidate hotspot data identifier; and when the candidate hot spot data identification identical to the to-be-accessed data identification exists, determining that the to-be-accessed data corresponding to the to-be-accessed data identification is in the candidate hot spot data list.
In one embodiment, the processor, when executing the computer program, further performs the steps of: when the data to be accessed corresponding to the data identification to be accessed is not in the candidate hot spot data list, determining a corresponding default fragment according to the data identification to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identification to be accessed; and responding to the access request through the default fragment, and acquiring an access result corresponding to the data identifier to be accessed.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double Data Rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), rambus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (9)

1. A cache system hotspot data access method comprises the following steps:
receiving an access request of a cache system, wherein the access request carries a data identifier to be accessed;
when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hotspot data list, acquiring a preset routing scheduling rule;
routing the access request to a target fragment according to the preset routing scheduling rule, responding the access request through the target fragment, and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier;
when the data to be accessed corresponding to the data identifier to be accessed is not in the candidate hotspot data list, determining a corresponding default fragment according to the data identifier to be accessed, wherein the default fragment is a fragment specially used for processing an access request corresponding to the data identifier to be accessed;
responding to the access request through the default fragment, and acquiring an access result corresponding to the to-be-accessed data identifier;
the step of responding to the access request through the target fragment and acquiring an access result corresponding to the to-be-accessed data identifier includes:
when the target fragment is pre-loaded with candidate hot spot data, and when an access request is routed to the target fragment, the target fragment directly responds to the access request to obtain an access result corresponding to the data identifier to be accessed;
when the target fragment does not pre-load the candidate hot data, recording the access times of the access requests corresponding to the same to-be-accessed data identification through a preset timer, when the access times reach a preset access time threshold value, loading the candidate hot data through the target fragment, and after the target fragment finishes the loading of the hot data, when the access requests are routed to the target fragment, responding to the access requests by the target fragment to obtain the access results corresponding to the to-be-accessed data identification.
2. The method of claim 1, wherein prior to receiving the cache system access request, comprising:
acquiring candidate hotspot data, wherein the candidate hotspot data comprise corresponding candidate hotspot data identifiers;
acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment;
traversing each candidate fragment to enable the candidate fragment to load the candidate hot spot data;
and generating a candidate hot spot data list according to the candidate hot spot data.
3. The method of claim 2, further comprising:
acquiring preset failure time corresponding to each candidate hotspot data;
and when the preset failure time is reached, removing the corresponding candidate hot spot data from the candidate hot spot data list to obtain an updated candidate hot spot data list.
4. The method of claim 1, wherein after receiving the cache system access request, further comprising:
acquiring a preset counter;
responding to the access request through the preset counter, and acquiring the current access times corresponding to the data identification to be accessed;
when the current access times do not reach an access time threshold value, determining whether the data to be accessed corresponding to the data identification to be accessed is in the candidate hotspot data list or not;
and entering the step of acquiring a preset routing scheduling rule when the data to be accessed corresponding to the data to be accessed identifier is determined to be in the candidate hotspot data list.
5. The method of claim 4, further comprising:
when the current access times reach an access times threshold value, acquiring a candidate fragment set, wherein the candidate fragment set comprises at least one candidate fragment;
traversing each candidate fragment, and loading the data to be accessed through each candidate fragment;
acquiring a current counting state corresponding to the preset counter;
and setting the current counting state as a current failure state, and determining that the preset counter does not count any more.
6. The method according to claim 1, wherein when the data to be accessed identifies that the corresponding data to be accessed is in a candidate hotspot data list, the method includes:
acquiring a candidate hotspot data list, wherein the candidate hotspot data list comprises each candidate hotspot data, and each candidate hotspot data comprises a corresponding candidate hotspot data identifier;
and when the candidate hotspot data identification identical to the to-be-accessed data identification exists, determining that the to-be-accessed data corresponding to the to-be-accessed data identification is in a candidate hotspot data list.
7. An apparatus for implementing the cache system hot spot data access method of claim 1, wherein the apparatus comprises:
the access request receiving module is used for receiving an access request of the cache system, wherein the access request carries a data identifier to be accessed;
the routing rule obtaining module is used for obtaining a preset routing scheduling rule when the data to be accessed corresponding to the data to be accessed identifier is in the candidate hot spot data list;
and the access result generating module is used for routing the access request to a target fragment according to the preset routing scheduling rule, responding the access request through the target fragment and acquiring an access result corresponding to the to-be-accessed data identifier, wherein the target fragment is not a fragment specially used for processing the access request corresponding to the to-be-accessed data identifier.
8. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the steps of the method of any of claims 1 to 6 are implemented when the computer program is executed by the processor.
9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 6.
CN202010850146.0A 2020-08-21 2020-08-21 Cache system hot spot data access method, device, equipment and storage medium Active CN112115167B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202010850146.0A CN112115167B (en) 2020-08-21 2020-08-21 Cache system hot spot data access method, device, equipment and storage medium
CA3128540A CA3128540C (en) 2020-08-21 2021-08-17 Cache system hotspot data access method, apparatus, computer device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010850146.0A CN112115167B (en) 2020-08-21 2020-08-21 Cache system hot spot data access method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112115167A CN112115167A (en) 2020-12-22
CN112115167B true CN112115167B (en) 2022-11-18

Family

ID=73804332

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010850146.0A Active CN112115167B (en) 2020-08-21 2020-08-21 Cache system hot spot data access method, device, equipment and storage medium

Country Status (2)

Country Link
CN (1) CN112115167B (en)
CA (1) CA3128540C (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113225396B (en) * 2021-04-30 2022-08-12 深圳市腾讯网域计算机网络有限公司 Hot spot data packet distribution method and device, electronic equipment and medium
CN113676531B (en) * 2021-08-16 2023-10-31 北京百度网讯科技有限公司 E-commerce flow peak clipping method and device, electronic equipment and readable storage medium
CN113806651B (en) * 2021-09-18 2024-05-24 深圳市酷开网络科技股份有限公司 Data caching method, device, server and storage medium
CN115996227A (en) * 2022-12-23 2023-04-21 中国联合网络通信集团有限公司 Data sharing method, device, system, server and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107346307A (en) * 2016-05-04 2017-11-14 北京京东尚科信息技术有限公司 Distributed cache system and method
CN107506369A (en) * 2017-07-06 2017-12-22 联动优势科技有限公司 A kind of data access method and equipment
US20190042133A1 (en) * 2018-06-29 2019-02-07 Intel Corporation Technologies for providing adaptive data access request routing in a distributed storage system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107346307A (en) * 2016-05-04 2017-11-14 北京京东尚科信息技术有限公司 Distributed cache system and method
CN107506369A (en) * 2017-07-06 2017-12-22 联动优势科技有限公司 A kind of data access method and equipment
US20190042133A1 (en) * 2018-06-29 2019-02-07 Intel Corporation Technologies for providing adaptive data access request routing in a distributed storage system

Also Published As

Publication number Publication date
CA3128540C (en) 2024-01-02
CA3128540A1 (en) 2022-02-21
CN112115167A (en) 2020-12-22

Similar Documents

Publication Publication Date Title
CN112115167B (en) Cache system hot spot data access method, device, equipment and storage medium
CN110008118B (en) Page data testing method and device, computer equipment and storage medium
CN107832100B (en) APK plug-in loading method and terminal thereof
CN109492019B (en) Service request response method, device, computer equipment and storage medium
CN110602169B (en) Service calling method and device, computer equipment and storage medium
CN112000541A (en) Buried point data reporting method and device, computer equipment and storage medium
CN112099979B (en) Access control method, device, computer equipment and storage medium
CN110267060B (en) Video file storage injection method and device, computer equipment and storage medium
CN112181532B (en) Page resource loading method and device, electronic equipment and readable storage medium
CN112764948A (en) Data transmission method, data transmission device, computer device, and storage medium
CN109257426B (en) Service line resource loading method and device, computer equipment and storage medium
CN111885184A (en) Method and device for processing hot spot access keywords in high concurrency scene
US11394748B2 (en) Authentication method for anonymous account and server
CN105893150B (en) Interface calling frequency control method and device and interface calling request processing method and device
CN110049535B (en) Network searching method, device, equipment and storage medium
CN111597480A (en) Webpage resource preloading method and device, computer equipment and storage medium
CN111046240A (en) Gateway flow statistical method, device, computer equipment and storage medium
CN115357779A (en) Data processing method, device and system, electronic equipment and storage medium
CN112433779B (en) Application site preloading method, device and storage medium based on ERP system
CN112800123A (en) Data processing method, data processing device, computer equipment and storage medium
CN114422530A (en) Flow control method and device, computer equipment and storage medium
CN112783866A (en) Data reading method and device, computer equipment and storage medium
CN112463783A (en) Index data monitoring method and device, computer equipment and storage medium
CN110019031B (en) File creation method and file management device
CN113051157B (en) Interface testing method and device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant