dlmarion commented on code in PR #4229:
URL: https://github.com/apache/accumulo/pull/4229#discussion_r1478911877


##########
server/base/src/main/java/org/apache/accumulo/server/manager/state/TabletGoalState.java:
##########
@@ -84,6 +85,15 @@ public static TabletGoalState compute(TabletMetadata tm, 
TabletState currentStat
         return TabletGoalState.UNASSIGNED;
       }
 
+      // When the tablet has wals and it will not be hosted normally, then 
cause it to
+      // be hosted so that recovery can occur. When tablet availability is 
ONDEMAND or
+      // UNHOSTED, then this tablet will eventually become unhosted after 
recovery occurs.
+      // This could cause a little bit of churn on the cluster w/r/t 
balancing, but it's
+      // necessary.
+      if (!tm.getLogs().isEmpty() && tm.getTabletAvailability() != 
TabletAvailability.HOSTED) {

Review Comment:
   There was conversation in #3844 about the fact that if wals are not 
processed, then they hang around forever and are not GC'd. I'm taking the 
approach here that  a) a failure occurred that caused a tablet to not close 
cleanly and b) we should always clean that up.



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