HBASE优化写入速度
(1)
hbase.regionserver.handler.count=100 (原始值30)
(2)
HTable htable = new HTable(config, tablename); htable.setWriteBufferSize(10 * 1024 * 1024); htable.setAutoFlush(false);
设置buffer的容量,例子中设置了10MB的buffer容量。
禁止auto flush。
(3)
Put put = new Put(rowKey); put.setWriteToWAL(false);
关闭WAL