HBase Mode Case Height_Width_ 中 Architecture Design Smackdown

Thanks for sharing the platform- http://bjbsair.com/2020-04-10/tech-info/53343.html

This article will introduce other pattern design issues that appear in remote lists, especially regarding height and width tables. These are general guidelines and not laws-every application must take into account its own needs.

HBase line and version

A common question is whether you should prefer the line or the built-in version of HBase. The context is usually where "multiple" versions of the row are kept (for example, it is significantly higher than the HBase default of the 1 largest version). rows-approach needs to store a timestamp in some parts of the rowkey so that they will not be overwritten each time they are updated continuously.

Preferences: OK (in general).

HBase rows and columns

Another common question is whether rows or columns should be preferred. The context is usually in the extreme case of a wide table, such as having 1 million attributes per row, or 1 column per 1 million rows.

Preferences: OK (in general). It should be noted that this guide is a very broad situation in context, not a standard use case, in which dozens or hundred columns need to be stored. But there is also an intermediate path between these two options, which is "rows as columns".

HBase rows as columns

The intermediate path between HBase rows and columns will pack the data, and for some rows, these data will become separate rows. In this case, OpenTSDB is the best example, where a row represents a defined time range and then treats discrete events as columns. This method is usually more complex and may require additional complexity to rewrite the data, but has the advantage of efficient I / O.

Guess you like

Origin blog.51cto.com/14744108/2486402