Interface DistributionSchedule.AckSet

  • Enclosing interface:

    public static interface DistributionSchedule.AckSet
    An ack set represents the set of bookies from which a response must be received so that an entry can be considered to be replicated on a quorum.
    • Method Detail

      • completeBookieAndCheck

        boolean completeBookieAndCheck​(int bookieIndexHeardFrom)
        Add a bookie response and check if quorum has been met.
        true if quorum has been met, false otherwise
      • failBookieAndCheck

        boolean failBookieAndCheck​(int bookieIndexHeardFrom,
                                   BookieId address)
        Received failure response from a bookie and check if ack quorum will be broken.
        bookieIndexHeardFrom - bookie index that failed.
        address - bookie address
        true if ack quorum is broken, false otherwise.
      • getFailedBookies

        java.util.Map<java.lang.Integer,​BookieId> getFailedBookies()
        Return the list of bookies that already failed.
        the list of bookies that already failed.
      • removeBookieAndCheck

        boolean removeBookieAndCheck​(int bookie)
        Invalidate a previous bookie response. Used for reissuing write requests.
      • recycle

        void recycle()
        Recycle this ack set when not used anymore.