Method and system for managing memory data and maintaining data in memory

Through the design of multi-shard data table structure and skip table, the problem of long read/write time and small number of tasks in the database when processing data quickly is solved, and efficient data processing and parallel processing capabilities are achieved.

CN110704194BActive Publication Date: 2024-09-27THE FOURTH PARADIGM BEIJING TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910973093.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2018-07-06
Publication Date
2024-09-27
Estimated Expiration
2038-07-06

AI Technical Summary

Technical Problem

When existing databases need to process data quickly and perform a large number of data writing tasks and query tasks, there are problems such as long time reading/writing of data and a small number of data writing and query tasks per unit time.

Method used

Adopt a multi-shard data table structure, use the first-level and second-level jump tables to store the first attribute value and the second attribute value of the data respectively, determine the shards through the hash value, and store them in chronological order in the second-level jump table Arrange nodes to improve data read/write speed and parallel processing capabilities.

Benefits of technology

It improves the data reading/writing speed, increases the number of data writing and query tasks that can be executed simultaneously per unit time, and improves the processing efficiency of the database.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110704194B
    Figure CN110704194B
Patent Text Reader

Abstract

Provided are a method and system for managing memory data, a method and system for maintaining data in memory, and a computer-readable medium and a computing device corresponding to the provided method and system. The method for managing memory data comprises: setting a data table including a plurality of shards, wherein each shard corresponds to a first-level skip table; setting the first-level skip table to store a node with a first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; setting the second-level skip table to store a node with a second attribute value of the data as a keyword and a value corresponding to the keyword including at least one attribute value of the data. According to the present invention, the time consumption of reading / writing data can be reduced, and the number of data writing tasks and / or data query tasks executed simultaneously per unit time can be increased.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of a patent application with application date of July 6, 2018, application number 201810735798.2, and titled “Method and system for maintaining data in memory”. Technical Field

[0002] The present invention generally relates to the field of memory data management and maintenance, and more specifically, to a method and system for managing memory data, a method and system for maintaining data in memory, and corresponding computer-readable media and computing devices. Background Art

[0003] Existing databases include relational databases and non-relational databases. Relational databases such as MySQL and SQL Server are mainly used to manage and maintain relational data. Non-relational databases such as Redis and MongoDB are mainly used to manage and maintain non-relational data. Relational data refers to data based on the relational model (RM). Non-relational data refers to data that is not based on the relational model.

[0004] In order to process time series data, a time series database (TSDB) such as InfluxDB is proposed. In order to manage data in memory, a memory database such as VoltDB is proposed.

[0005] However, in specific scenarios where data needs to be processed quickly and a large number of data writing tasks and / or data query tasks need to be executed simultaneously, traditional databases including the databases listed above have the problem of long time consumption in reading / writing data, and also have the problem of a small number of data writing tasks and / or data query tasks that can be executed simultaneously per unit time. Summary of the invention

[0006] An exemplary embodiment of the present invention is to provide a method and system for managing memory data, a method and system for maintaining data in memory, and a computer-readable medium and a computing device corresponding to the provided method and system, so as to solve the problem of long time consumption in reading / writing data in the prior art, and the problem of small number of data writing tasks and / or data query tasks that can be executed simultaneously per unit time.

[0007] According to an exemplary embodiment of the present invention, a method for managing memory data is provided. The method for managing memory data comprises: setting a data table including a plurality of shards, wherein each shard corresponds to a first-level skip table; setting the first-level skip table to be used for storing a node with a first attribute value of data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; setting the second-level skip table to be used for storing a node with a second attribute value of the data as a keyword and a value corresponding to the keyword including at least one attribute value of the data.

[0008] According to another exemplary embodiment of the present invention, a method for maintaining data in memory is provided. The method for maintaining data in memory comprises: determining a fragment corresponding to the data to be inserted in a data table including multiple fragments according to the first attribute value of the data to be inserted, wherein each fragment corresponds to a first-level skip table, and the first-level skip table is used to store nodes with the first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; searching for a node with the first attribute value of the data to be inserted as a keyword from the first-level skip table corresponding to the determined fragment; when a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip table, adding a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword including at least one attribute value of the data to be inserted in the second-level skip table indicated by the pointer or object in the found node.

[0009] Optionally, the step of determining the shard corresponding to the data to be inserted includes: calculating a hash value corresponding to a first attribute value of the data to be inserted; obtaining a remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determining the shard corresponding to the obtained remainder as the shard corresponding to the data to be inserted.

[0010] Optionally, each of the multiple slices stores a pointer or object indicating a corresponding first-level skip table.

[0011] Optionally, the method for maintaining data in memory also includes: if a node with the first attribute value of the data to be inserted as a keyword cannot be found in the first-level skip list, creating a second-level skip list, creating a node in the first-level skip list with the first attribute value of the data to be inserted as a keyword and a pointer or object indicating the created second-level skip list as a value corresponding to the keyword, and adding a node in the created second-level skip list with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword including the at least one attribute value of the data to be inserted.

[0012] Optionally, the at least one attribute value of the data to be inserted includes the first attribute value and / or the second attribute value of the data to be inserted, or the at least one attribute value of the data to be inserted includes neither the first attribute value of the data to be inserted nor the second attribute value of the data to be inserted, wherein the value corresponding to the second attribute value of the data to be inserted in the node added to the second-level skip list includes a string obtained in one of the following ways: merging the at least one attribute value according to a predetermined string merging rule, serializing the at least one attribute value according to a predetermined JSON format, serializing the at least one attribute value according to a predetermined ProtocolBuffer format, and serializing the at least one attribute value according to a predefined Schema format.

[0013] Optionally, the method for maintaining data in memory also includes: receiving a first attribute value of the data to be queried and a value range for a second attribute value; determining a shard in the data table corresponding to the data to be queried based on the first attribute value of the data to be queried; searching for a node with the first attribute value of the data to be queried as a keyword from a first-level skip list corresponding to the determined shard; and taking out at least one corresponding attribute value in a node whose keyword is within the value range from a second-level skip list indicated by a pointer or object in the found node.

[0014] Optionally, the step of extracting at least one attribute value corresponding to a node in which the keyword is within a value range from a second-level skip list indicated by a pointer or object in the found node includes: extracting a value corresponding to the keyword within the value range from a node in the second-level skip list indicated by a pointer or object in the found node; obtaining at least one attribute value of the data to be queried in one of the following ways: splitting the extracted value according to a predetermined string splitting rule, deserializing the extracted value according to a predetermined JSON format, deserializing the extracted value according to a predetermined ProtocolBuffer format, and deserializing the extracted value according to a predefined Schema format.

[0015] Optionally, the step of determining the shard corresponding to the data to be queried includes: calculating a hash value corresponding to a first attribute value of the data to be queried; obtaining a remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determining the shard corresponding to the obtained remainder as the shard corresponding to the data to be queried.

[0016] Optionally, the data to be inserted or the data to be queried is time series data, and the second attribute value is a timestamp value.

[0017] Optionally, the value range specifies a starting value and an ending value of a timestamp value or specifies an ending value of a timestamp value.

[0018] Optionally, the step of adding nodes in the second-level skip list includes: adding nodes according to the time indicated by the timestamp value, so that the nodes in the second-level skip list are arranged in order from near to far in time.

[0019] Optionally, the method for maintaining data in memory also includes: setting a node quantity threshold corresponding to a second-level skip list, wherein the step of extracting the corresponding at least one attribute value in the node whose keyword is within a value range from the second-level skip list indicated by a pointer or object in the found node includes: extracting the corresponding at least one attribute value in the node whose keyword is within the value range and whose number does not exceed the node quantity threshold in order from near to far.

[0020] Optionally, the method for maintaining data in memory also includes: setting a node number threshold corresponding to a second-level skip list; traversing the first-level skip list and the second-level skip list at a predetermined period, and when the number of nodes in the traversed second-level skip list exceeds the node number threshold, deleting all nodes after the node corresponding to the node number threshold according to the arrangement order of the nodes in the second-level skip list.

[0021] Optionally, the method for maintaining data in memory further includes: setting an expiration period length; traversing the first-level skip list and the second-level skip list at a predetermined period, and deleting the nodes after the node as a whole by locating the node whose timestamp value reaches the expiration period length.

[0022] According to another exemplary embodiment of the present invention, a system for managing memory data is provided. The system for managing memory data includes: a data table setting unit, used to set a data table including multiple shards, wherein each shard corresponds to a first-level skip table; a first-level skip table setting unit, used to set the first-level skip table to a node for storing a first attribute value of data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; a second-level skip table setting unit, used to set the second-level skip table to a node for storing a second attribute value of the data as a keyword and a value corresponding to the keyword including at least one attribute value of the data.

[0023] According to another exemplary embodiment of the present invention, a system for maintaining data in memory is provided. The system for maintaining data in memory includes: a shard determination unit, which is used to determine the shard corresponding to the data to be inserted in the data table including multiple shards according to the first attribute value of the data to be inserted, wherein each shard corresponds to a first-level skip table, and the first-level skip table is used to store nodes with the first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; a search unit, which is used to search for a node with the first attribute value of the data to be inserted as a keyword from the first-level skip table corresponding to the determined shard; and a data adding unit, which is used to add a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword includes at least one attribute value of the data to be inserted in the second-level skip table indicated by the pointer or object in the found node when a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip table.

[0024] Optionally, the shard determination unit calculates a hash value corresponding to a first attribute value of the data to be inserted; obtains a remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determines the shard corresponding to the obtained remainder as the shard corresponding to the data to be inserted.

[0025] Optionally, each of the multiple slices stores a pointer or object indicating a corresponding first-level skip table.

[0026] Optionally, if a node whose first attribute value of the data to be inserted is not found in the first-level skip list as a keyword, the data adding unit creates a second-level skip list, creates a node in the first-level skip list whose first attribute value of the data to be inserted is a keyword and whose pointer or object indicating the created second-level skip list is a value corresponding to the keyword, and adds a node in the created second-level skip list whose second attribute value of the data to be inserted is a keyword and whose value corresponding to the keyword includes the at least one attribute value of the data to be inserted.

[0027] Optionally, the at least one attribute value of the data to be inserted includes the first attribute value and / or the second attribute value of the data to be inserted, or the at least one attribute value of the data to be inserted includes neither the first attribute value of the data to be inserted nor the second attribute value of the data to be inserted, wherein the value corresponding to the second attribute value of the data to be inserted in the node added to the second-level skip list includes a string obtained in one of the following ways: merging the at least one attribute value according to a predetermined string merging rule, serializing the at least one attribute value according to a predetermined JSON format, serializing the at least one attribute value according to a predetermined ProtocolBuffer format, and serializing the at least one attribute value according to a predefined Schema format.

[0028] Optionally, the system for maintaining data in memory further includes: an input receiving unit and a data acquisition unit, wherein the input receiving unit receives a first attribute value of the data to be queried and a value range of a second attribute value, the shard determination unit determines the shard corresponding to the data to be queried in the data table according to the first attribute value of the data to be queried, and the data acquisition unit searches for a node with the first attribute value of the data to be queried as a keyword from a first-level skip list corresponding to the determined shard, and retrieves the corresponding at least one attribute value in the node whose keyword is within the value range from a second-level skip list indicated by a pointer or object in the found node.

[0029] Optionally, the data acquisition unit takes out a value corresponding to a keyword within a value range from a node of a second-level skip list indicated by a pointer or object in the found node, and obtains at least one attribute value of the data to be queried in one of the following ways: splitting the taken out value according to a predetermined string splitting rule, deserializing the taken out value according to a predetermined JSON format, deserializing the taken out value according to a predetermined ProtocolBuffer format, or deserializing the taken out value according to a predefined Schema format.

[0030] Optionally, the shard determination unit calculates a hash value corresponding to a first attribute value of the data to be queried, obtains a remainder obtained by dividing the calculated hash value by the total number of shards in the data table, and determines the shard corresponding to the obtained remainder as the shard corresponding to the data to be queried.

[0031] Optionally, the data to be inserted or the data to be queried is time series data, and the second attribute value is a timestamp value.

[0032] Optionally, the value range specifies a starting value and an ending value of a timestamp value or specifies an ending value of a timestamp value.

[0033] Optionally, the data adding unit adds the node according to the time indicated by the timestamp value, so that the nodes in the second-level skip list are arranged in order from near to far in time.

[0034] Optionally, the system for maintaining data in memory also includes: a node quantity threshold setting unit, used to set a node quantity threshold corresponding to a second-level skip list, wherein the data acquisition unit retrieves, in order from near to far, from the second-level skip list indicated by a pointer or object in the found node, the corresponding at least one attribute value in the nodes whose keywords are within the value range and whose quantity does not exceed the node quantity threshold.

[0035] Optionally, the system for maintaining data in memory also includes: a node number threshold setting unit and a node deletion unit, wherein the node number threshold setting unit sets a node number threshold corresponding to the second-level jump list, and the search unit traverses the first-level jump list and the second-level jump list in a predetermined period, and when the number of nodes in the traversed second-level jump list exceeds the node number threshold, the node deletion unit deletes all nodes after the node corresponding to the node number threshold according to the arrangement order of the nodes in the second-level jump list.

[0036] Optionally, the system for maintaining data in memory also includes: an expiration period setting unit and a data deletion unit, wherein the expiration period setting unit sets the expiration period, the search unit traverses the first-level skip list and the second-level skip list in a predetermined period, and the data deletion unit integrally deletes the nodes after the node whose timestamp value reaches the expiration period.

[0037] According to another exemplary embodiment of the present invention, a computer readable medium is provided, on which a computer program for executing the method for managing memory data as described above is recorded.

[0038] According to another exemplary embodiment of the present invention, a computing device is provided, including a storage component and a processor, wherein a computer executable instruction set is stored in the storage component, and when the computer executable instruction set is executed by the processor, the method for managing memory data as described above is executed.

[0039] According to another exemplary embodiment of the present invention, a computer-readable medium is provided, wherein a computer program for executing the method of maintaining data in a memory as described above is recorded on the computer-readable medium.

[0040] According to another exemplary embodiment of the present invention, a computing device is provided, including a storage component and a processor, wherein a set of computer executable instructions is stored in the storage component, and when the set of computer executable instructions is executed by the processor, the method of maintaining data in the memory as described above is performed.

[0041] According to the method, system, computer-readable medium and computing device of the exemplary embodiments of the present invention, a first-level skip table and a second-level skip table can be set, wherein the first-level skip table stores nodes with the first attribute value of the data as a keyword and a pointer or object indicating the second-level skip table as a value corresponding to the keyword, and the second-level skip table stores nodes with the second attribute value of the data as a keyword, thereby enabling the nodes in the second-level skip table to be quickly located using the preset keyword corresponding to the first attribute value and the keyword corresponding to the second attribute value, thereby improving the data reading / writing speed; multiple shards and a first-level skip table corresponding to each shard are also set, thereby increasing the number of data writing tasks and / or data query tasks that can be executed simultaneously per unit time by processing the multiple shards in parallel.

[0042] Additional aspects and / or advantages of the present general inventive concept will be set forth in part in the following description and in part will be obvious from the description, or may be learned through practice of the present general inventive concept. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] The above and other objects and features of the exemplary embodiments of the present invention will become more apparent through the following description in conjunction with the accompanying drawings which exemplarily illustrate the embodiments, in which:

[0044] Figure 1 A schematic diagram showing a data table according to an exemplary embodiment of the present invention;

[0045] Figure 2 A flow chart showing a method for managing memory data according to an exemplary embodiment of the present invention;

[0046] Figure 3 A flow chart showing an operation of inserting data in a memory according to an exemplary embodiment of the present invention;

[0047] Figure 4 A flow chart showing an operation of querying data in a memory according to an exemplary embodiment of the present invention;

[0048] Figure 5 A block diagram showing a system for managing memory data according to an exemplary embodiment of the present invention;

[0049] Figure 6 A block diagram of a system for maintaining data in memory according to an exemplary embodiment of the present invention is shown. DETAILED DESCRIPTION

[0050] Reference will now be made in detail to embodiments of the present invention, examples of which are shown in the accompanying drawings, wherein like reference numerals refer to like parts throughout. The embodiments will be described below with reference to the drawings in order to explain the present invention.

[0051] The first-level skip list and the second-level skip list involved in the exemplary embodiment of the present invention are skiplists, also called skip lists.

[0052] Figure 1 Schematic diagram of a data table according to an exemplary embodiment of the present invention is shown. Figure 1 As shown in , the data table according to the exemplary embodiment of the present invention includes slices 0 to n, where n is a natural number greater than 1. Each of these slices corresponds to a first-level skip table. Figure 1 , the first-level skip table corresponding to shard 0 is shown in FIG. The first-level skip table corresponding to shard 0 includes nodes 11 to 1m, where m is a natural number. A pointer or object indicating the corresponding first-level skip table can be stored in each shard to facilitate locating the first-level skip table corresponding to the shard.

[0053] Each node in the first level of hops can correspond to a second level hop table. Figure 1 As shown in , the second-level skip table corresponding to node 11 includes nodes 41 to 4k, the second-level skip table corresponding to node 12 includes nodes 31 to 3j, and the second-level skip table corresponding to node 1m includes nodes 21 to 2i, where i, j, and k are natural numbers. A pointer or object indicating the corresponding second-level skip table can be stored in each node of the first-level skip table to facilitate locating the second-level skip table corresponding to the node of the first-level skip table.

[0054] A key-value pair may be set in a node of a skip list. Specifically, for a node of a first-level skip list, a first attribute value of data may be set as a key, and a pointer or object indicating a second-level skip list may be set as a value corresponding to the key; for a node in a second-level skip list, a second attribute value of the data may be set as a key, and the value corresponding to the key may be used to store at least one attribute value of the data.

[0055] As an example, the at least one attribute value includes a first attribute value and / or a second attribute value of the data, or the at least one attribute value includes neither the first attribute value nor the second attribute value of the data.

[0056] In addition, in the node of the first level skip list, a pointer or an object indicating another node in this first level skip list can be stored. In the node of the second level skip list, a pointer or an object indicating another node in this second level skip list can also be stored.For the first level skip list or the second level skip list, when there was already a node in the skip list, an object or a pointer indicating a node belonging to a skip list with this node was stored in each node except the tail node, so that the skip list is formed into a chain structure.When inserting the 3rd node between first node and second node, the pointer or the object indicating the second node in the first node need to be changed into the 3rd node indicating, and in the 3rd node, utilize pointer or object to indicate second node.

[0057] Figure 2 FIG. 2 is a flow chart showing a method for managing memory data according to an exemplary embodiment of the present invention. Figure 2 As shown in FIG. 1 , the method for managing memory data according to an exemplary embodiment of the present invention includes steps S101 to S103 .

[0058] In step S101, a data table including a plurality of slices is set, wherein each slice corresponds to a first-level skip table. The plurality of slices may be set in a memory in the manner of setting an array in a memory, and then a corresponding first-level skip table may be set for each slice. The first-level skip table initially set may be an empty skip table, in which no node exists. A pointer or object indicating a corresponding first-level skip table may be stored in each of the plurality of slices, so that the corresponding first-level skip table may be located through the pointer or object.

[0059] In step S102, the first-level skip table is set to a node for storing a first attribute value of data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword. A key-value pair is stored in each node of the first-level skip table, wherein the first attribute value of the data is used as a keyword, and the pointer or object is used as a value corresponding to the keyword. In step S103, the second-level skip table is set to a node for storing a second attribute value of the data as a keyword and the value corresponding to the keyword includes at least one attribute value of the data. A key-value pair is also stored in each node of the second-level skip table, wherein the second attribute value is used as a keyword, and the value corresponding to the keyword includes at least one attribute value of the data. When the data is bank transaction data, the first attribute value may be a card number, the second attribute value may be a timestamp value, and the value corresponding to the timestamp value may include at least one of a transaction amount value, a transaction location, or a point of sale (POS) number. Table 1 below shows data according to an exemplary embodiment of the present invention:

[0060] Table 1

[0061] card number Timestamp value Transaction amount value Trading location POS Number 6222XXXX01 2018052814520505 100 Beijing Shangdi xx Road 10xxx 6222XXXX01 2018052815520505 50 Beijing Xi'erqi xx store 20xxx 6222XXXX02 2018052811520505 1000 Nanjing Gulou Districtxxx 30xxx

[0062] As shown in Table 1, each piece of data may include the following attribute values: card number, timestamp value, transaction amount value, transaction location, and POS number. Table 1 includes 3 pieces of data.

[0063] As an example, the at least one attribute value of the data includes the first attribute value and / or the second attribute value of the data, or the at least one attribute value of the data includes neither the first attribute value of the data nor the second attribute value of the data. The value corresponding to the second attribute value of the data in the node added to the second-level skip list includes a string obtained by one of the following ways: merging the at least one attribute value according to a predetermined string merging rule, serializing the at least one attribute value according to a predetermined JSON (such as JavaScript Object Notation, which is called JS object representation) format, serializing the at least one attribute value according to a predetermined ProtocolBuffer format, and serializing the at least one attribute value according to a predefined Schema format.

[0064] The above-mentioned shards, first-level skip tables, and second-level skip tables may be set in a memory. By setting the first-level skip table and the second-level skip table in the above-mentioned manner, a correspondence between the shards, the first-level skip table, and the second-level skip table may be set, and data in the memory may be managed and maintained based on the set correspondence. The operation of maintaining data in the memory will be described in the following exemplary embodiments.

[0065] Figure 3 1 is a flow chart showing an operation of inserting data into a memory according to an exemplary embodiment of the present invention. Figure 3 As shown in FIG. 1 , the operation of maintaining data in the memory according to an exemplary embodiment of the present invention includes steps S201 to S203 .

[0066] As an example, insertion can be performed through the interface form of put(table_name, key, ts, value), where table_name is used to limit the name of the data table into which the data will be inserted, key is used to limit the first attribute value of the data to be inserted, ts is used to limit the second attribute value of the data to be inserted, and value is used to limit at least one attribute value of the data to be inserted (as an example, the value can be a value obtained by encoding (for example, merging or serializing) the at least one attribute value according to specific rules).

[0067] As an example, insertion can also be performed through the interface form of put(table_name, key, ts, field_1, field_1 type, field_2, field_2 type, ……, field_n, field_n type), where table_name is used to define the name of the data table into which the data to be inserted will be inserted, key is used to define the first attribute value of the data to be inserted, ts is used to define the second attribute value of the data to be inserted, and field_1, field_1 type, field_2, field_2 type, ……, field_n, field_n type are used to define n attribute values (Schema format) of the data to be inserted, and n is a natural number.

[0068] In step S201, based on the first attribute value of the data to be inserted, determine the shard in the data table including multiple shards that corresponds to the data to be inserted, where each shard corresponds to a first-level skiplist, and the first-level skiplist is used to store nodes with the first attribute value of the data as the keyword and a pointer or object indicating the second-level skiplist as the value corresponding to the keyword.

[0069] In an exemplary embodiment of the present invention, the data to be inserted can be received. For example, the bank transaction data shown in Table 1. The bank transaction data may include the following attribute values: card number, timestamp value, transaction amount value, transaction location, and POS number. The data table into which the data to be inserted will be inserted can be selected from the in-memory database. Multiple shards are stored in the selected data table.

[0070] The shard corresponding to the data to be inserted can be selected in the following manner: calculate the hash value corresponding to the first attribute value of the data to be inserted; obtain the remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determine the shard corresponding to the obtained remainder as the shard corresponding to the data to be inserted. A hash function can be used to calculate the first attribute value to obtain the hash value. For example, the hash function used can be the hash function Murmurhash proposed by Austin Appleby. Of course, the present invention does not limit the hash function used, and other hash functions can also be used for the calculation of the hash value. Refer to Figure 1 , the data table may include shard 0 to shard n. If the remainder is 0, then shard 0 corresponds to the data to be inserted; if the remainder is h (0 < h ≤ n), then shard h corresponds to the data to be inserted.

[0071] As an example, a slice can be associated with a first-level skip list through a pointer or an object. That is, a pointer or an object indicating a corresponding first-level skip list is stored in each slice of a plurality of slices of a data table. The object is similar to an object involved in object-oriented (OO) programming technology. Through the pointer or object stored in the slice, the first-level skip list corresponding to the slice can be located.

[0072] In step S202, a node with a first attribute value of the data to be inserted as a keyword is searched from the first-level skip list corresponding to the determined fragment.

[0073] In step S203, when a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip list, a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword includes at least one attribute value of the data to be inserted is added to the second-level skip list indicated by the pointer or object in the found node.

[0074] As an example, the data to be inserted is time series data, and the second attribute value is a timestamp value.

[0075] As an example, if after the first-level skip list corresponding to the determined fragment is established, a node with the first attribute value of the data to be inserted as a keyword has not been inserted into the first-level skip list, the result of the search in step S202 is empty. In this case, a second-level skip list can be created, and a node with the first attribute value of the data to be inserted as a keyword and a pointer or object indicating the created second-level skip list as a value corresponding to the keyword can be created in the first-level skip list. Subsequently, a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword including at least one attribute value of the data to be inserted can be added to the created second-level skip list.

[0076] Take the data to be inserted as the first data in Table 1 as an example. In step S201, assume that the corresponding fragment is determined to be fragment 0 according to the card number value "6222XXXX01". Figure 1 , search for a node with "6222XXXX01" as a keyword from the first-level skip table corresponding to slice 0. For example, node 11 is found. Based on this, it can be determined that the second-level skip table corresponding to node 11 includes nodes 41 to 4k.

[0077] As an example, the at least one attribute value of the data to be inserted includes the first attribute value and / or the second attribute value of the data to be inserted, or the at least one attribute value of the data to be inserted includes neither the first attribute value of the data to be inserted nor the second attribute value of the data to be inserted, wherein the value corresponding to the second attribute value of the data to be inserted in the node added to the second-level skip list includes a string obtained by one of the following methods: merging the at least one attribute value according to a predetermined string merging rule, serializing the at least one attribute value according to a predetermined JSON format, serializing the at least one attribute value according to a predetermined ProtocolBuffer format, and serializing the at least one attribute value according to a predefined Schema format.

[0078] As an example, the predetermined string merging rule includes merging according to a specific symbol (e.g., "|"). For example, the transaction amount value, transaction location value, and POS number value can be merged into a string "100|Beijing Shangdi xx Road|10xxx" according to a pre-set symbol such as "|", and a node 4g (g is a natural number) with "2018052814520505" as a keyword and "100|Beijing Shangdi xx Road|10xxx" as a value corresponding to the keyword is set, and the set node 4g is inserted into the second-level skip list, for example, between node 41 and node 42. In addition to obtaining a string by merging the at least one attribute value according to a predetermined string merging rule, the above-mentioned method of obtaining a string as a value corresponding to the keyword in the node of the second-level skip list using JSON format, ProtocolBuffer format, and Schema format is also feasible. Of course, the above description is only an example and should not be regarded as a limitation.

[0079] As an example, the step of adding a node in the second-level skip list includes: adding the node according to the time indicated by the timestamp value, so that the nodes in the second-level skip list are arranged in order from near to far in time. The distance of time can be determined by comparing the timestamp values, and the time corresponding to a larger timestamp value is closer than the time corresponding to a smaller timestamp value. Therefore, in the second-level skip list, the node with a larger timestamp value can be arranged before the node with a smaller timestamp value.

[0080] The data to be inserted is the 1st to 3rd data in Table 1 as an example for explanation. The 1st data and the 2nd data have the same card number, so these two data correspond to the same second-level skip table. In the second-level skip table, after the 1st data is added, the timestamp value of the 2nd data is larger than the timestamp value of the 1st data, so the node corresponding to the 2nd data is added before the node corresponding to the 1st data. In the second-level skip table, insert node 4g with "2018052814520505" as the keyword and "100|Beijing Shangdi xx Road|10xxx" as the value corresponding to the keyword, and insert a node with "2018052815520505" as the keyword and "50|Beijing Xierqi xx Store|20xxx" as the value corresponding to the keyword before node 4g.

[0081] In the above example, the shard corresponding to the third data is determined to be shard 1 according to the card number value "6222XXXX02", and the first-level jump table corresponding to shard 1 is determined according to the pointer or object stored in shard 1 ( Figure 1 The first-level skip table corresponding to shard 1 is not shown in the figure). Assuming that the node with "6222XXXX02" as the keyword is not found in the first-level skip table corresponding to shard 1, a node and a second-level skip table are created, and a node with "6222XXXX02" as the keyword and a pointer or object indicating the created second-level skip table as the value corresponding to the keyword is added to the created second-level skip table. Subsequently, a node with "2018052811520505" as the keyword and "1000|Nanjing Gulou District xxx|30xxx" as the value corresponding to the keyword is added to the created second-level skip table.

[0082] Figure 4 FIG. 2 is a flowchart showing an operation of querying data in a memory according to an exemplary embodiment of the present invention. Figure 4 As shown in , the operation of querying data in the memory according to an exemplary embodiment of the present invention includes steps S301 to S304.

[0083] As an example, the query can be performed through the interface form of scan(table_name, key, start_time, end_time), where table_name is used to limit the name of the data table from which data is queried, key is used to limit the first attribute value of the data to be queried, start_time and end_time are used to limit the value range of the data to be queried, for example, the start time and the end time.

[0084] As an example, the query can be performed through the interface form of get(table_name, key, ts), where table_name is used to limit the name of the data table from which data is queried, key is used to limit the first attribute value of the data to be queried, and ts is used to limit the value range of the data to be queried. For example, ts is used to limit the timestamp value of the data to be queried. In this case, the data actually expected to be queried is the data with a timestamp value of ts; for another example, ts is used to limit the end time of the data to be queried. In this case, the data actually expected to be queried is the data from the time of querying the data to the specified ts.

[0085] In step S301, a first attribute value of data to be queried and a value range of a second attribute value are received.

[0086] As an example, the data to be queried is time series data, and the second attribute value is a timestamp value.

[0087] As an example, the value range specifies a start value and an end value of a timestamp value or specifies an end value of a timestamp value.

[0088] In step S302, the slice corresponding to the data to be queried in the data table is determined according to the first attribute value of the data to be queried.

[0089] As an example, the shard corresponding to the data to be queried can be determined by the following operations: calculating a hash value corresponding to the first attribute value of the data to be queried; obtaining a remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determining the shard corresponding to the obtained remainder as the shard corresponding to the data to be queried. The first attribute value can be calculated using a hash function to obtain a hash value. For example, the hash function used can be Murmurhash, a hash function proposed by Austin Appleby. Of course, the present invention does not limit the hash function used, and other hash functions can also be used to calculate the hash value.

[0090] In step S303, a node with the first attribute value of the data to be queried as a keyword is searched from the first-level skip list corresponding to the determined fragment.

[0091] In step S304, the at least one attribute value corresponding to the node whose keyword is within the value range is retrieved from the second-level skip list indicated by the pointer or object in the found node.

[0092] Taking the data in Table 1 as an example, it is necessary to query the data whose card number value is "6222XXXX01" and whose starting value of the timestamp value is "2018052815520505" and whose ending value is "2018052814520505". According to "6222XXXX01", it is determined that the slice corresponding to the data to be queried is slice 0. From the node 11 node 1m of the first-level skip table corresponding to slice 0, it is found that the node with "6222XXXX01" as the keyword is node 11. It is determined that the second-level skip table corresponding to node 11 includes nodes 41 to 4k. From nodes 41 to 4k, nodes whose starting value of the key value is "2018052815520505" and whose ending value is "2018052814520505" are found, so that the value corresponding to the keyword can be found from the found node. For example, when the value range only specifies the end value of the timestamp value (for example, "2018052814520505"), it can be used to query data corresponding to nodes whose timestamp values ​​are greater than or equal to "2018052814520505".

[0093] As an example, the step of extracting the corresponding at least one attribute value in the node whose keyword is within the value range from the second-level skip list indicated by the pointer or object in the found node includes: extracting the value corresponding to the keyword within the value range from the node of the second-level skip list indicated by the pointer or object in the found node; obtaining the at least one attribute value of the data to be queried in one of the following ways: splitting the extracted value according to a predetermined string splitting rule (corresponding to the above-mentioned string merging rule), deserializing the extracted value according to a predetermined JSON format, deserializing the extracted value according to a predetermined ProtocolBuffer format, and deserializing the extracted value according to a predefined Schema format.

[0094] For example, the values ​​corresponding to the keywords found from the found nodes are "100|Beijing Shangdi xx Road|10xxx" and "50|Beijing Xi'erqi xx store|20xxx". "100|Beijing Shangdi xx Road|10xxx" can be split according to a preset symbol such as "|", and according to the preset meaning of the split strings, the first split string is obtained as the transaction amount value "100", the second split string is the transaction location "Beijing Shangdi xx Road", and the third split string is the POS number "10xxx". Similarly, the transaction amount value "50", the transaction location "Beijing Xi'erqi xx store" and the POS number "20xxx" can be obtained from "50|Beijing Xi'erqi xx store|20xxx".

[0095] As an example, in order to ensure that too much data is not stored in the memory, a threshold value of the number of nodes corresponding to the second-level skip list may be set. On this basis, the step of taking out the corresponding at least one attribute value in the node whose keyword is within the value range from the second-level skip list indicated by the pointer or object in the found node includes: taking out the corresponding at least one attribute value in the node whose keyword is within the value range and the number of which does not exceed the threshold value of the number of nodes from the second-level skip list indicated by the pointer or object in the found node in the order from near to far.

[0096] As an example, regular deletion can also be performed according to a set node quantity threshold, that is, the first-level skip list and the second-level skip list are traversed at a predetermined period, and when the number of nodes in the traversed second-level skip list exceeds the node quantity threshold, all nodes after the node corresponding to the node quantity threshold are deleted according to the arrangement order of the nodes in the second-level skip list. For example, when the node quantity threshold is 10, according to the arrangement order of the nodes in the second-level skip list, the node corresponding to the node quantity threshold is the 10th node.

[0097] As an example, in order to improve processing efficiency, the following expired data deletion operation can be performed: set the expiration period length; traverse the first-level skip list and the second-level skip list in a predetermined period (for example, 3 months), and locate the node whose timestamp value reaches the expiration period length to delete the nodes after the node as a whole. Through the expired data deletion operation, the nodes in the second-level skip list whose timestamp value is less than the timestamp value corresponding to the set expiration period length can be deleted. For example, if the timestamp value corresponding to the set expiration period length is 20180600000000000, the three nodes corresponding to the three data in Table 1 added to the second-level skip list in the above example can be deleted through the above expired data deletion operation.

[0098] Figure 5 A block diagram of a system for managing memory data according to an exemplary embodiment of the present invention is shown. Figure 5 As shown in FIG. 4 , a system 400 for managing memory data according to an exemplary embodiment of the present invention includes: a data table setting unit 401 , a first-level skip table setting unit 402 , and a second-level skip table setting unit 403 .

[0099] The data table setting unit 401 is used to set a data table including a plurality of shards, wherein each shard corresponds to a first-level skip table. The first-level skip table setting unit 402 is used to set the first-level skip table to a node for storing a first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword. The second-level skip table setting unit 403 is used to set the second-level skip table to a node for storing a second attribute value of the data as a keyword and a value corresponding to the keyword including at least one attribute value of the data.

[0100] Figure 6 A block diagram of a system for maintaining data in memory according to an exemplary embodiment of the present invention is shown. Figure 6 As shown in FIG. 5 , a system 500 for maintaining data in a memory according to an exemplary embodiment of the present invention includes: a shard determination unit 501 , a search unit 502 , and a data adding unit 503 .

[0101] The shard determination unit 501 is used to determine the shard corresponding to the data to be inserted in the data table including multiple shards according to the first attribute value of the data to be inserted, wherein each shard corresponds to the first-level skip table, and the first-level skip table is used to store nodes with the first attribute value of the data as a keyword and a pointer or object indicating the second-level skip table as a value corresponding to the keyword. The search unit 502 is used to search for a node with the first attribute value of the data to be inserted as a keyword from the first-level skip table corresponding to the determined shard. The data adding unit 503 is used to add a node with the second attribute value of the data to be inserted as a keyword in the case where a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip table, and the value corresponding to the keyword includes at least one attribute value of the data to be inserted in the second-level skip table indicated by the pointer or object in the found node.

[0102] As an example, the shard determination unit 501 calculates a hash value corresponding to a first attribute value of the data to be inserted; obtains a remainder obtained by dividing the calculated hash value by the total number of shards in the data table; and determines the shard corresponding to the obtained remainder as the shard corresponding to the data to be inserted.

[0103] As an example, each of the plurality of slices stores a pointer or an object indicating a corresponding first-level skip table.

[0104] As an example, when a node with the first attribute value of the data to be inserted as a keyword cannot be found in the first-level skip list, the data adding unit 503 creates a second-level skip list, creates a node in the first-level skip list with the first attribute value of the data to be inserted as a keyword and a pointer or object indicating the created second-level skip list as a value corresponding to the keyword, and adds a node in the created second-level skip list with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword includes the at least one attribute value of the data to be inserted.

[0105] As an example, the at least one attribute value of the data to be inserted includes the first attribute value and / or the second attribute value of the data to be inserted, or the at least one attribute value of the data to be inserted includes neither the first attribute value of the data to be inserted nor the second attribute value of the data to be inserted, wherein the value corresponding to the second attribute value of the data to be inserted in the node added to the second-level skip list includes a string obtained by one of the following methods: merging the at least one attribute value according to a predetermined string merging rule, serializing the at least one attribute value according to a predetermined JSON format, serializing the at least one attribute value according to a predetermined ProtocolBuffer format, and serializing the at least one attribute value according to a predefined Schema format.

[0106] As an example, the system for maintaining data in memory also includes: an input receiving unit (not shown) and a data acquisition unit (not shown), wherein the input receiving unit receives a first attribute value of the data to be queried and a value range for a second attribute value, wherein the shard determination unit 501 determines the shard corresponding to the data to be queried in the data table according to the first attribute value of the data to be queried; the data acquisition unit searches for a node with the first attribute value of the data to be queried as a keyword from a first-level skip table corresponding to the determined shard, and takes out the corresponding at least one attribute value in the node whose keyword is within the value range from a second-level skip table indicated by a pointer or object in the found node.

[0107] As an example, the data acquisition unit takes out the value corresponding to the keyword within the value range from the node of the second-level jump table indicated by the pointer or object in the found node, and obtains the at least one attribute value of the data to be queried in one of the following ways: splitting the taken out value according to a predetermined string splitting rule, deserializing the taken out value according to a predetermined JSON format, deserializing the taken out value according to a predetermined ProtocolBuffer format, and deserializing the taken out value according to a predefined Schema format.

[0108] As an example, the shard determination unit 501 calculates a hash value corresponding to a first attribute value of the data to be queried; obtains a remainder obtained by dividing the calculated hash value by the total number of shards in the data table, and determines the shard corresponding to the obtained remainder as the shard corresponding to the data to be queried.

[0109] As an example, the data to be inserted or the data to be queried is time series data, and the second attribute value is a timestamp value.

[0110] As an example, the value range specifies a start value and an end value of a timestamp value or specifies an end value of a timestamp value.

[0111] As an example, the data adding unit 503 adds nodes according to the time indicated by the timestamp value, so that the nodes in the second-level skip list are arranged in order from near to far in time.

[0112] As an example, the system for maintaining data in memory also includes: a node quantity threshold setting unit (not shown), which is used to set a node quantity threshold corresponding to a second-level skip list, wherein the data acquisition unit retrieves the corresponding at least one attribute value from the nodes whose keywords are within the value range and whose quantity does not exceed the node quantity threshold from the second-level skip list indicated by the pointer or object in the found node in order from near to far.

[0113] As an example, a system for maintaining data in memory also includes: a node deletion unit, wherein a node number threshold setting unit sets a node number threshold corresponding to a second-level jump list, and a search unit traverses the first-level jump list and the second-level jump list in a predetermined period, and when the number of nodes in the traversed second-level jump list exceeds the node number threshold, the node deletion unit deletes all nodes after the node corresponding to the node number threshold according to the arrangement order of the nodes in the second-level jump list.

[0114] As an example, the system for maintaining data in memory also includes: an expiration period setting unit (not shown) and a data deletion unit (not shown), wherein the expiration period length setting unit sets the expiration period length, the search unit traverses the first-level skip list and the second-level skip list in a predetermined period, and the data deletion unit deletes the nodes after the nodes whose timestamp values ​​reach the expiration period length as a whole.

[0115] It should be understood that the specific implementation of the system for managing memory data and the system for maintaining data in memory according to the exemplary embodiment of the present invention can be referred to in conjunction with Figures 1 to 4 The relevant specific implementation methods described in Table 1 are used to implement it, which will not be repeated here.

[0116] The units included in the system according to the exemplary embodiment of the present invention may be configured as software, hardware, firmware or any combination of the above items to perform specific functions. For example, these units may correspond to a dedicated integrated circuit, or may correspond to pure software code, or may correspond to a unit combining software and hardware. In addition, one or more functions implemented by these units may also be uniformly executed by components in a physical entity device (e.g., a processor, a client or a server, etc.).

[0117] It should be understood that the method according to an exemplary embodiment of the present invention can be implemented by a program recorded on a computer-readable medium. For example, according to an exemplary embodiment of the present invention, a computer-readable medium for managing memory data can be provided, wherein a computer program for executing the following method steps is recorded on the computer-readable medium: a data table including multiple shards is set, wherein each shard corresponds to a first-level skip table; the first-level skip table is set to store a node with a first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; the second-level skip table is set to store a node with a second attribute value of the data as a keyword and the value corresponding to the keyword includes at least one attribute value of the data.

[0118] For another example, according to an exemplary embodiment of the present invention, a computer-readable medium for maintaining data in a memory may be provided, wherein a computer program for executing the following method steps is recorded on the computer-readable medium: determining a fragment corresponding to the data to be inserted in a data table including multiple fragments according to the first attribute value of the data to be inserted, wherein each fragment corresponds to a first-level skip table, and the first-level skip table is used to store nodes with the first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; searching for a node with the first attribute value of the data to be inserted as a keyword from the first-level skip table corresponding to the determined fragment; when a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip table, adding a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword including at least one attribute value of the data to be inserted to the second-level skip table indicated by the pointer or object in the found node.

[0119] The computer program in the computer-readable medium can be run in an environment deployed in a computer device such as a client, a host, an agent device, a server, etc. It should be noted that the computer program can also be used to perform additional steps in addition to the above steps or perform more specific processing when performing the above steps. The contents of these additional steps and further processing have been referred to in Figures 1 to 4 And Table 1 has been described, and will not be repeated here to avoid repetition.

[0120] It should be noted that the system according to the exemplary embodiment of the present invention can completely rely on the operation of the computer program to realize the corresponding functions, that is, each unit corresponds to each step in the functional architecture of the computer program, so that the entire system is called through a special software package (for example, lib library) to realize the corresponding functions.

[0121] On the other hand, the various units included in the system according to the exemplary embodiment of the present invention can also be implemented by hardware, software, firmware, middleware, microcode or any combination thereof. When implemented by software, firmware, middleware or microcode, the program code or code segment for performing the corresponding operation can be stored in a computer-readable medium such as a storage medium, so that the processor can perform the corresponding operation by reading and running the corresponding program code or code segment.

[0122] For example, an exemplary embodiment of the present invention may also be implemented as a computing device, which includes a storage component and a processor, wherein a set of computer-executable instructions is stored in the storage component, and when the set of computer-executable instructions is executed by the processor, a method for managing memory data or a method for maintaining data in memory is executed.

[0123] Specifically, the computing device may be deployed in a server or client, or may be deployed on a node device in a distributed network environment. In addition, the computing device may be a PC, a tablet device, a personal digital assistant, a smart phone, a web application, or other device capable of executing the above instruction set.

[0124] Here, the computing device is not necessarily a single computing device, but may be any device or circuit collection that can execute the above instructions (or instruction sets) individually or jointly. The computing device may also be part of an integrated control system or system manager, or may be configured as a portable electronic device that is interconnected with a local or remote (e.g., via wireless transmission) interface.

[0125] In the computing device, the processor may include a central processing unit (CPU), a graphics processing unit (GPU), a programmable logic device, a dedicated processor system, a microcontroller or a microprocessor. By way of example and not limitation, the processor may also include an analog processor, a digital processor, a microprocessor, a multi-core processor, a processor array, a network processor, etc.

[0126] Some operations described in the method according to the exemplary embodiment of the present invention may be implemented by software, some operations may be implemented by hardware, and furthermore, these operations may be implemented by a combination of software and hardware.

[0127] The processor may execute instructions or codes stored in one of the storage components, which may also store data. Instructions and data may also be sent and received over a network via a network interface device, which may employ any known transmission protocol.

[0128] The storage component may be integrated with the processor, for example, RAM or flash memory is arranged within an integrated circuit microprocessor, etc. In addition, the storage component may include a separate device, such as an external disk drive, a storage array, or any other storage device that can be used by a database system. The storage component and the processor may be operatively coupled, or may communicate with each other, such as through an I / O port, a network connection, etc., so that the processor can read files stored in the storage component.

[0129] In addition, the computing device may also include a video display (such as a liquid crystal display) and a user interaction interface (such as a keyboard, a mouse, a touch input device, etc.) All components of the computing device may be connected to each other via a bus and / or a network.

[0130] The operations involved in the method for managing memory data and / or the method for maintaining data in memory according to an exemplary embodiment of the present invention can be described as various interconnected or coupled functional blocks or functional diagrams. However, these functional blocks or functional diagrams can be equally integrated into a single logical device or operated according to non-exact boundaries.

[0131] For example, as described above, a computing device for managing memory data according to an exemplary embodiment of the present invention may include a storage component and a processor, wherein a computer executable instruction set is stored in the storage component, and when the computer executable instruction set is executed by the processor, the following steps are performed: a data table including a plurality of shards is set, wherein each shard corresponds to a first-level skip table; the first-level skip table is set to be used to store a node with a first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; the second-level skip table is set to be used to store a node with a second attribute value of the data as a keyword and a value corresponding to the keyword including at least one attribute value of the data.

[0132] For another example, as described above, a computing device for maintaining data in a memory according to an exemplary embodiment of the present invention may include a storage component and a processor, wherein a computer executable instruction set is stored in the storage component, and when the computer executable instruction set is executed by the processor, the following steps are performed: determining a shard corresponding to the data to be inserted in a data table including multiple shards according to the first attribute value of the data to be inserted, wherein each shard corresponds to a first-level skip table, and the first-level skip table is used to store nodes with the first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; searching for a node with the first attribute value of the data to be inserted as a keyword from the first-level skip table corresponding to the determined shard; when a node with the first attribute value of the data to be inserted as a keyword is found in the first-level skip table, adding a node with the second attribute value of the data to be inserted as a keyword and the value corresponding to the keyword including at least one attribute value of the data to be inserted in the second-level skip table indicated by the pointer or object in the found node.

[0133] The above describes various exemplary embodiments of the present invention, it should be understood that the above description is only exemplary, not exhaustive, and the present invention is not limited to the disclosed exemplary embodiments. Without departing from the scope and spirit of the present invention, many modifications and changes are obvious to those of ordinary skill in the art. Therefore, the scope of protection of the present invention should be based on the scope of the claims.

Claims

1. A method for managing memory data, comprising: Setting a data table including a plurality of slices, wherein each slice corresponds to a first-level skip table; The first-level skip table is set to store a node with the first attribute value of the data as a key and a pointer or object indicating the second-level skip table as a value corresponding to the key; The second-level skip table is set to store a node with a second attribute value of the data as a key and a value corresponding to the key including at least one attribute value of the data.

2. A system for managing memory data, comprising: A data table setting unit, used to set a data table including a plurality of slices, wherein each slice corresponds to a first-level skip table; A first-level skip table setting unit, used to set the first-level skip table to be a node for storing a first attribute value of the data as a keyword and a pointer or object indicating a second-level skip table as a value corresponding to the keyword; The second-level skip table setting unit is used to set the second-level skip table to store a node with a second attribute value of the data as a key and a value corresponding to the key including at least one attribute value of the data.

3. A computer-readable medium, wherein: A computer program for executing the method according to claim 1 is recorded on the computer readable medium.

4. A computing device comprising a storage component and a processor, wherein: A computer executable instruction set is stored in the storage component. When the computer executable instruction set is executed by the processor, the method according to claim 1 is executed.