Skip to content

Commit 2ad62b0

Browse files
virajjasanisaintstack
authored andcommitted
HBASE-22679 : Revamping CellUtil (#735)
* HBASE-22679 : Revamping CellUtil * checkstyle fix * incorporating review * minor indentation
1 parent 6e96738 commit 2ad62b0

File tree

23 files changed

+413
-864
lines changed

23 files changed

+413
-864
lines changed

hbase-client/src/main/java/org/apache/hadoop/hbase/protobuf/ProtobufUtil.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -687,8 +687,12 @@ private static <T extends Mutation> T toDelta(Function<Bytes, T> supplier, Consu
687687
if (qv.hasTags()) {
688688
tags = qv.getTags().toByteArray();
689689
}
690-
consumer.accept(mutation, CellUtil.createCell(mutation.getRow(), family, qualifier, qv.getTimestamp(),
691-
KeyValue.Type.Put, value, tags));
690+
consumer.accept(mutation, ExtendedCellBuilderFactory.create(CellBuilderType.DEEP_COPY)
691+
.setRow(mutation.getRow()).setFamily(family)
692+
.setQualifier(qualifier).setTimestamp(qv.getTimestamp())
693+
.setType(KeyValue.Type.Put.getCode()).setValue(value)
694+
.setTags(tags).setSequenceId(0)
695+
.build());
692696
}
693697
}
694698
}

hbase-common/src/main/java/org/apache/hadoop/hbase/ByteBufferKeyValue.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ public int getValueLength() {
180180

181181
@Override
182182
public byte[] getTagsArray() {
183-
return CellUtil.cloneTags(this);
183+
return PrivateCellUtil.cloneTags(this);
184184
}
185185

186186
@Override

0 commit comments

Comments
 (0)