Class BlockingPartitionRepair

All Implemented Interfaces:
com.google.common.util.concurrent.ListenableFuture<Object>, io.netty.util.concurrent.Future<Object>, Future<Object>, RequestCallback<Object>, Awaitable, Future<Object>

public class BlockingPartitionRepair extends AsyncFuture<Object> implements RequestCallback<Object>
  • Constructor Details

  • Method Details

    • onResponse

      public void onResponse(Message<Object> msg)
      Specified by:
      onResponse in interface RequestCallback<Object>
      Parameters:
      msg - response received.
    • sendRR

      protected void sendRR(Message<Mutation> message, InetAddressAndPort endpoint)
    • sendInitialRepairs

      public void sendInitialRepairs()
    • awaitRepairsUntil

      public boolean awaitRepairsUntil(long timeoutAt, TimeUnit timeUnit)
      Wait for the repair to complete util a future time If the is a past time, the method returns immediately with the repair result.
      Parameters:
      timeoutAt - future time
      timeUnit - the time unit of the future time
      Returns:
      true if repair is done; otherwise, false.
    • maybeSendAdditionalWrites

      public void maybeSendAdditionalWrites(long timeout, TimeUnit timeoutUnit)
      If it looks like we might not receive acks for all the repair mutations we sent out, combine all the unacked mutations and send them to the minority of nodes not involved in the read repair data read / write cycle. We will accept acks from them in lieu of acks from the initial mutations sent out, so long as we receive the same number of acks as repair mutations transmitted. This prevents misbehaving nodes from killing a quorum read, while continuing to guarantee monotonic quorum reads