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

Indexing method and device based on key value pair KV system, electronic equipment and medium

A key-value pair and index technology, applied in the computer field, can solve problems such as low index efficiency, and achieve the effect of improving reading speed, improving reading efficiency, and saving memory resources

Pending Publication Date: 2020-06-05
BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF7 Cites 5 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] The embodiment of the present application provides an indexing method, device, electronic device and medium based on a key-value pair KV system, which can solve the problem of low indexing efficiency caused by the existing KV indexing method when the amount of data is too large

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Indexing method and device based on key value pair KV system, electronic equipment and medium
  • Indexing method and device based on key value pair KV system, electronic equipment and medium
  • Indexing method and device based on key value pair KV system, electronic equipment and medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0065] Figure 1A It is a schematic flowchart of an indexing method based on a key-value pair KV system provided in Embodiment 1 of the present application. This embodiment is applicable to the situation where the KV system is used to query the corresponding value through the key value, and can be executed by the indexing device based on the KV system provided in the embodiment of the present application, and the device can be implemented by software and / or hardware. Such as Figure 1A As shown, the method may include:

[0066] S101. Obtain the key value in the key-value pair to be queried, wherein the key value of each key-value pair in the KV system is an incremental integer number.

[0067] Among them, the key-value pair is composed of the key value Key and the value Value, which is used to represent the correspondence between the value and the key value. A key value can correspond to one value or multiple values. For example, if the key value is "age", its The correspondi...

Embodiment 2

[0109] Figure 2A It is a schematic flowchart of an indexing method based on a key-value pair KV system provided in Embodiment 2 of the present application. This embodiment provides a specific implementation method for the above-mentioned embodiments. This specific implementation method is suitable for solving the problem in the prior art that when the amount of data is too large, the use of the first-level index leads to excessive memory usage, such as Figure 2A As shown, the method may include:

[0110] S201. Obtain the key value in the key-value pair to be queried, wherein the key value of each key-value pair in the KV system is an incremental integer number.

[0111] S202. Use the key value as the primary index serial number, and determine the secondary index serial number of the index block corresponding to the serial number range of the primary index serial number, wherein each index block corresponds to a set number of primary index serial numbers.

[0112] Exemplary...

Embodiment 3

[0126] Figure 3A It is a schematic flowchart of an indexing method based on a key-value pair KV system provided in Embodiment 3 of the present application. This embodiment provides a specific implementation for the above embodiments. This embodiment is applicable to the situation of reading the value in the key-value pair to be queried when the value is of the POD type, such as Figure 3A As shown, the method may include:

[0127] S301. Obtain the key value in the key-value pair to be queried, wherein the key value of each key-value pair in the KV system is an incremental integer number.

[0128] S302. Use the key value as the primary index serial number, and determine the secondary index serial number of the index block corresponding to the serial number range of the primary index serial number, wherein each index block corresponds to a set number of primary index serial numbers.

[0129] Specifically, in this embodiment, the index block corresponds to the element space of t...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses an indexing method and device based on a key value pair KV system, electronic equipment and a medium, and relates to the technical field of indexing. According to the specificimplementation scheme, the method comprises the steps: acquiring key values in key value pairs to be inquired, wherein the key values of the key value pairs in the KV system are progressively increased integer numbers; taking the key value as a serial number of a fixed-length type index, and determining address information of a storage position where a numerical value in the to-be-queried key value pair is located according to the serial number; and reading a numerical value in the to-be-queried key value pair from a storage space according to the address information. According to the method,the obtained key values are used as the serial number of the fixed-length type index, so that the resource occupation amount of a system memory is reduced; by determining the address information of the storage position where the numerical value is located according to the serial number, the numerical value reading is completed, the numerical value reading speed is increased, and the numerical value reading efficiency is improved.

Description

technical field [0001] The embodiments of the present application relate to computer technology, in particular to indexing technology, and in particular to an indexing method, device, electronic device and medium based on a key-value pair KV system. Background technique [0002] KV (Key Value, keyword-value) retrieval is a type of NoSQL (Not OnlySQL, non-relational database) retrieval engine that is currently very common in the industry. This type of system has high retrieval performance and large-scale update throughput. [0003] The index information in the existing KV search stores the key value and the mapping relationship between the key value and the address information of the corresponding data. When querying the target data, firstly, the target key is found in the index information based on the set data structure. value, and then query the data content of the target data according to the mapping relationship between the target key value and the address information of...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F16/22
CPCG06F16/2228
Inventor 汪洋宋勋超袁鹏程王益飞张海平
Owner BEIJING BAIDU NETCOM SCI & TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products