imbajin commented on code in PR #1864:
URL:
https://github.com/apache/incubator-hugegraph/pull/1864#discussion_r867607473
##########
hugegraph-hbase/src/main/java/com/baidu/hugegraph/backend/store/hbase/HbaseSessions.java:
##########
@@ -222,19 +226,21 @@ public void createTable(String table, List<byte[]> cfs)
throws IOException {
.build());
}
tdb.setCoprocessor(COPROCESSOR_AGGR);
- try(Admin admin = this.hbase.getAdmin()) {
+ try (Admin admin = this.hbase.getAdmin()) {
admin.createTable(tdb.build());
}
}
- public void createPreSplitTable(String table, List<byte[]> cfs, short
numOfPartitions) throws IOException {
+ public void createPreSplitTable(String table, List<byte[]> cfs,
+ short numOfPartitions) throws IOException {
TableDescriptorBuilder builder = TableDescriptorBuilder.newBuilder(
TableName.valueOf(this.namespace, table));
for (byte[] cf : cfs) {
builder.setColumnFamily(ColumnFamilyDescriptorBuilder.newBuilder(cf)
.build());
}
- byte[][] splits = new byte[numOfPartitions -
1][org.apache.hadoop.hbase.util.Bytes.SIZEOF_SHORT];
+ byte[][] splits = new byte[numOfPartitions - 1]
+
[org.apache.hadoop.hbase.util.Bytes.SIZEOF_SHORT];
Review Comment:
seems divide it makes a little strange for readable
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]