keith-turner commented on code in PR #5340:
URL: https://github.com/apache/accumulo/pull/5340#discussion_r1992287624
##########
core/src/main/java/org/apache/accumulo/core/metadata/schema/TabletMetadata.java:
##########
@@ -558,6 +559,26 @@ private static Optional<TServerInstance>
checkServer(ClientContext context, Stri
.map(address -> new TServerInstance(address,
stat.getEphemeralOwner()));
}
+ public static void validate(TabletMetadata tm) {
+ if (!tm.fetchedCols.contains(ColumnType.FILES) || !tm.sawPrevEndRow) {
Review Comment:
If we fetched files, may not see any files for a tablet can avoid some work
by checking if the set is empty. The `sawPrevEndRow` is more for error
checking. If we fetched the PREV_ROW then its always expeced that it will be
seen, so can check if it was fetched. Other code will throw an error if prev
row was fetched and not seen.
```suggestion
if (files.isEmpty() || !tm.fetchedCols.contains(ColumnType.PREV_ROW)) {
```
--
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]