code: @Override
    public synchronized void handlePeerChoked(SharingPeer peer) {
      Set<Piece> pieces = peer.getRequestedPieces();
  
      if (pieces.size() > 0) {
        for (Piece piece : pieces) {
          this.requestedPieces.set(piece.getIndex(), false);
        }
      }
  
      logger.trace("Peer {} choked, we now have {} outstanding " +
                      "request(s): {}.",
              new Object[]{
                      peer,
                      this.requestedPieces.cardinality(),
                      this.requestedPieces
              });
    }
docs: Peer choked handler.
  <p/>
  <p>
  When a peer chokes, the requests made to it are canceled and we need to
  mark the eventually piece we requested from it as available again for
  download tentative from another peer.
  </p>
  
  @param peer The peer that choked.