kevinrr888 commented on code in PR #5952:
URL: https://github.com/apache/accumulo/pull/5952#discussion_r2417297832
##########
core/src/main/java/org/apache/accumulo/core/clientImpl/TableOperationsImpl.java:
##########
@@ -2221,16 +2221,18 @@ private void validatePropertiesToSet(Map<String,String>
opts, Map<String,String>
}
@Override
- public void setTabletAvailability(String tableName, Range range,
TabletAvailability availability)
- throws AccumuloSecurityException, AccumuloException {
+ public void setTabletAvailability(String tableName, RowRange rowRange,
+ TabletAvailability availability) throws AccumuloSecurityException,
AccumuloException {
EXISTING_TABLE_NAME.validate(tableName);
if (SystemTables.containsTableName(tableName)) {
throw new AccumuloException("Cannot set set tablet availability for
table " + tableName);
}
- checkArgument(range != null, "range is null");
+ checkArgument(rowRange != null, "rowRange is null");
checkArgument(availability != null, "tabletAvailability is null");
+ Range range = rowRange.asRange();
+
byte[] bRange;
Review Comment:
RowRange is only used here to convert it to a Range, why not just keep it as
Range? Is RowRange just a better definition/better object to expect from API
perspective?
##########
core/src/main/java/org/apache/accumulo/core/clientImpl/TableOperationsImpl.java:
##########
@@ -2255,10 +2257,11 @@ public void setTabletAvailability(String tableName,
Range range, TabletAvailabil
}
@Override
- public Stream<TabletInformation> getTabletInformation(final String
tableName, final Range range,
- TabletInformation.Field... fields) throws TableNotFoundException {
+ public Stream<TabletInformation> getTabletInformation(final String tableName,
+ final RowRange rowRange, TabletInformation.Field... fields) throws
TableNotFoundException {
EXISTING_TABLE_NAME.validate(tableName);
+ final Range range = rowRange.asRange();
final Text scanRangeStart = (range.getStartKey() == null) ? null :
range.getStartKey().getRow();
Review Comment:
same question here
--
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]