tolbertam commented on code in PR #4139:
URL: https://github.com/apache/cassandra/pull/4139#discussion_r2074027111


##########
src/java/org/apache/cassandra/repair/autorepair/AutoRepair.java:
##########
@@ -449,20 +449,27 @@ private List<String> retrieveTablesToBeRepaired(Keyspace 
keyspace, AutoRepairCon
     }
 
     private void cleanupAndUpdateStats(RepairTurn turn, 
AutoRepairConfig.RepairType repairType, AutoRepairState repairState, UUID myId,
-                                       long startTime, CollectedRepairStats 
collectedRepairStats) throws InterruptedException
+                                       long startTimeInMillis, 
CollectedRepairStats collectedRepairStats) throws InterruptedException
     {
         //if it was due to priority then remove it now
         if (turn == MY_TURN_DUE_TO_PRIORITY)
         {
             logger.info("Remove current host from priority list");
             AutoRepairUtils.removePriorityStatus(repairType, myId);
         }
-
+        long repairScheduleElapsedInMillis = timeFunc.get() - 
startTimeInMillis;
+        if (repairScheduleElapsedInMillis < 
SLEEP_IF_REPAIR_FINISHES_QUICKLY.toMilliseconds())
+        {
+            //If repair finished quickly, happens for an empty instance, in 
such case

Review Comment:
   What makes an instance empty in this context?



-- 
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: pr-unsubscr...@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to