@Override
  public void run() {

    boolean blockMined = false;
    while (!blockMined && !minerBlockCreator.isCancelled()) {
      try {
        blockMined = mineBlock();
      } catch (final CancellationException ex) {
        LOG.debug("Block creation process cancelled.");
        break;
      } catch (final InterruptedException ex) {
        LOG.debug("Block mining was interrupted.", ex);
        Thread.currentThread().interrupt();
      } catch (final Exception ex) {
        LOG.error("Block mining threw an unhandled exception.", ex);
      }
    }
  }
Responsible for creating a block, and importing it to the blockchain. This is specifically a
mainnet capability (as IBFT would then use the block as part of a proposal round).

<p>While the capability is largely functional, it has been wrapped in an object to allow it to be
cancelled safely.

<p>This class is responsible for mining a single block only - the AbstractBlockCreator maintains
state so must be destroyed between block mining activities.
ethereum/blockcreation/src/main/java/org/hyperledger/besu/ethereum/blockcreation/BlockMiner.java