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

Method for constructing Hbase secondary index table

A secondary index and index table technology, applied in the database field, can solve the problems of machines exceeding their own capacity, unavailability of regions, time-consuming and resource-consuming, etc., and achieve the effect of improving operation access efficiency, improving parallel performance, and improving parallelism.

Pending Publication Date: 2020-05-26
ZHEJIANG HUAYUN INFORMATION TECH CO LTD
View PDF3 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

When the index table has only one partition when it is created, a large number of accesses will be concentrated on a single region. In addition, in the scenario of writing comparison frequency, as the data grows faster and faster, the number of splits will also increase, and splits are time-consuming. resource consuming
If the pre-partition is pre-built from the beginning, but because the prefix of the primary key of the index table is often the same consecutively and the order increases, this will still cause a large number of reads, writes or other operations to access one or a few nodes in the cluster. Cause a single machine where a hotspot region is located to exceed its own capacity, causing performance degradation or even region unavailability

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
  • Method for constructing Hbase secondary index table

Examples

Experimental program
Comparison scheme
Effect test

example

[0024] Such as figure 1 As shown, a method for constructing an Hbase secondary index table includes the following steps:

[0025] 1) Create an index table for the original table on the hbase table;

[0026] 2) For each record in the original table, generate a corresponding index record on the index table. The row key of the index record includes the partition key, index value, connector and primary key of the original table. The partition key is the start of the region where the index record is located The key field, the partition key is used as the primary key of the index table;

[0027] 3) Predefine the partition value;

[0028] 4) Predetermine the index partition value when building the index table;

[0029] 5) When creating an index table, pre-partition the index table according to the index partition value.

[0030] In order to improve parallel performance, in step 2), the partition key adopts a random hash distribution, combined with pre-partitioning of the index ta...

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

PUM

No PUM Login to View More

Abstract

The invention discloses a method for constructing an Hbase secondary index table, and relates to the field of databases. Hbase only provides query based on row keys and full-table scanning, full-tablescanning is needed when non-row keys are queried, and the query efficiency is low. The method comprises the following steps: establishing an index table for an original table on an hbase table; for each record of the original table, recording; generating corresponding index records on the index table, row keys of the index records comprise partition keys, index values, connectors and original table main keys, wherein the partition keys are start key fields of regions where the index records are located, the partition keys serve as the index table main keys, and pre-partitioning the partitionkeys in a random hash mode in combination with the index table; pre-defining the partition value; determining an index partition value in advance when an index table is established; and pre-partitioning the index table according to the index partition value when the index table is established. Parallel performance can be effectively improved, and query efficiency is improved.

Description

technical field [0001] The invention relates to the field of databases, in particular to a method for constructing an Hbase secondary index table. Background technique [0002] At present, the industry has proposed various solutions for the secondary index of Hbase. When the index table has only one partition when it is created, a large number of accesses will be concentrated on a single region. In addition, in the scenario of writing comparison frequency, as the data grows faster and faster, the number of splits will also increase, and splits are time-consuming. Resource consuming. If the pre-partition is pre-built from the beginning, but because the prefix of the primary key of the index table is often the same consecutively and the order increases, this will still cause a large number of reads, writes or other operations to access one or a few nodes in the cluster. A single machine where a hotspot region is located exceeds its own capacity, causing performance degradati...

Claims

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

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F16/22G06F16/2455
CPCG06F16/2264G06F16/2455
Inventor 胡峻朱慧君
Owner ZHEJIANG HUAYUN INFORMATION 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