public static long calculateExpirationWithDelay ( long timeInMillis , long delayMillis , boolean backup ) { checkNotNegative ( timeInMillis , "timeInMillis can't be negative" ) ; if ( backup ) { long delayedTime = timeInMillis + delayMillis ; // check for a potential long overflow if ( delayedTime < 0 ) { return Long . MAX_VALUE ; } else { return delayedTime ; } } return timeInMillis ; }
On backup partitions this method delays key s expiration .