private void queryPeers(final long blockNumber) {
    synchronized (runningQueries) {
      for (int i = 0; i < numberOfPeersToQuery; i++) {
        final CompletableFuture<?> query;
        if (synchronizerConfiguration.isPeerTaskSystemEnabled()) {
          query =
              executePivotQueryWithPeerTaskSystem(blockNumber)
                  .whenComplete(this::processReceivedHeader);
        } else {
          query = executePivotQuery(blockNumber).whenComplete(this::processReceivedHeader);
        }
        runningQueries.add(query);
      }
    }
  }
This task will query {@code numberOfPeersToQuery} peers for a particular block number. If any
peers disagree on the block at this number, the task fails with a {@code
ContestedPivotBlockException}. The task will succeed only if {@code numberOfPeersToQuery}
distinct peers all return matching block headers for the specified block number.
ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/sync/fastsync/PivotBlockConfirmer.java