如何使用HBase shell在Bigtable中设置表压缩模式?

时间:2017-05-10 16:09:17

标签: compression hbase google-cloud-bigtable

我正在使用HBase shell在Bigtable中创建表,而通常的create table命令可以指定压缩,但显然忽略了压缩属性。

示例:

hbase(main):003:0> create 'table_snappy', {NAME => 'event', VERSIONS => 1, COMPRESSION => 'SNAPPY', BLOOMFILTER => 'ROW'}
hbase(main):004:0> describe 'table_snappy'
Table table_snappy is ENABLED
table_snappy
COLUMN FAMILIES DESCRIPTION
{NAME => 'event', BLOOMFILTER => 'ROW', VERSIONS => '1', IN_MEMORY => 'false', KEEP_DELETED_CELLS => 'FALSE', DATA_BLOCK_ENCODING => 'NONE', TTL => 'FOREVER', COMPRESSION => 'NONE', MIN_VERSIONS => '0', BLOCKCACHE => 'true', BLOCKSIZE => '65536', REPLICATION_SCOPE => '0'}
1 row(s) in 0.0870 seconds

hbase(main):003:0> create 'table_lzo', {NAME => 'event', VERSIONS => 1, COMPRESSION => 'LZO', BLOOMFILTER => 'ROW'}
hbase(main):004:0> describe 'table_lzo'
Table table_lzo is ENABLED
table_lzo
COLUMN FAMILIES DESCRIPTION
{NAME => 'event', BLOOMFILTER => 'ROW', VERSIONS => '1', IN_MEMORY => 'false', KEEP_DELETED_CELLS => 'FALSE', DATA_BLOCK_ENCODING => 'NONE', TTL => 'FOREVER', COMPRESSION => 'NONE', MIN_VERSIONS => '0', BLOCKCACHE => 'true', BLOCKSIZE => '65536', REPLICATION_SCOPE => '0'}
1 row(s) in 0.0870 seconds

0 个答案:

没有答案