Beispiel #1
0
 public static boolean isRelevant(IColumn column, IColumnContainer container, int gcBefore) {
   // the column itself must be not gc-able (it is live, or a still relevant tombstone, or has live
   // subcolumns), (1)
   // and if its container is deleted, the column must be changed more recently than the container
   // tombstone (2)
   // (since otherwise, the only thing repair cares about is the container tombstone)
   long maxChange = column.mostRecentLiveChangeAt();
   return (!column.isMarkedForDelete()
           || column.getLocalDeletionTime() > gcBefore
           || maxChange > column.getMarkedForDeleteAt()) // (1)
       && (!container.isMarkedForDelete() || maxChange > container.getMarkedForDeleteAt()); // (2)
 }
 /**
  * Return whether a given column is deleted by the container having this deletion info.
  *
  * @param column the column to check.
  * @return true if the column is deleted, false otherwise
  */
 public boolean isDeleted(IColumn column) {
   return isDeleted(column.name(), column.mostRecentLiveChangeAt());
 }