hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arul Ramachandran <arkup...@gmail.com>
Subject While performing append operations, on region split, some of the data is lost
Date Fri, 02 Jan 2015 19:07:47 GMT
Hello folks,


We see the following behavior.

With append operation, data gets appended as expected until existing
regions are getting populated. But as soon as hbase does a split on one of
the region as it gets to its capacity, some of the append operations which
are already submitted to hbase get impacted. Due to this some of the data
is lost evident after running get operation on appended rows. We don't see
appended data.

Is this a bug or feature? Any comments/suggestions for work around?

code snippet:
List<Row> recordsToProcess = new ArrayList<Row>();
--- Loop through below code to generate multiple Append operations:
Append appendRow = new Append(Bytes.toBytes("rowKey");
for (String columnFamily : hBaseRow.getColumnValues().keySet()){
for(Entry<String, String> column :
byte[] columnFamilyName = Bytes.toBytes(columnFamily);
byte[] columnName = Bytes.toBytes(column.getKey());
byte[] columnValue = Bytes.toBytes(column.getValue());
appendRow.add(columnFamilyName, columnName, columnValue);

Object[] results = new Object[recordsToProcess.size()];
HTableInterface hTable = getHTable();
hTable.batch(recordsToProcess, results);


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message