keith-turner commented on a change in pull request #2320:
URL: https://github.com/apache/accumulo/pull/2320#discussion_r745781497



##########
File path: 
server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
##########
@@ -791,6 +791,27 @@ public void run() {
       }
     }, 0, 5000, TimeUnit.MILLISECONDS);
 
+    
ThreadPools.createGeneralScheduledExecutorService(aconf).scheduleWithFixedDelay(()
 -> {
+      final SortedMap<KeyExtent,Tablet> onlineTabletsSnapshot = 
onlineTablets.snapshot();
+      final SortedMap<KeyExtent,Pair<Long,TabletMetadata>> 
tabletValidationInfo = new TreeMap<>();
+
+      // gather update counters and metadata for all tablets
+      for (var entry : onlineTabletsSnapshot.entrySet()) {
+        KeyExtent keyExtent = entry.getKey();
+        Long counter = entry.getValue().getUpdateCounter();
+        TabletMetadata tm = getContext().getAmple().readTablet(keyExtent,
+            TabletMetadata.ColumnType.FILES, TabletMetadata.ColumnType.LOGS,
+            TabletMetadata.ColumnType.ECOMP, 
TabletMetadata.ColumnType.PREV_ROW);

Review comment:
       Just thought of one wrinkle with using readTablets(), it may not support 
reading different data levels at the same time. Like it may not support reading 
from the root tablet and a user tablet in the same call.  I am not sure though. 
 If so, this could be worked around or Ample could be improved to support that.




-- 
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]


Reply via email to