public static void propagateCancellation(
      final CompletableFuture<?> from, final CompletableFuture<?> to) {
    from.exceptionally(
        error -> {
          if (error instanceof CancellationException) {
            to.cancel(true);
          }
          return null;
        });
  }
Propagates cancellation, and only cancellation, from one future to another.

<p>When <code>from</code> is completed with a {@link
java.util.concurrent.CancellationException}* {@link
java.util.concurrent.Future#cancel(boolean)} will be called on <code>to</code>, allowing
interruption if the future is currently running.

@param from the CompletableFuture to take cancellation from
@param to the CompletableFuture to propagate cancellation to
util/src/main/java/org/hyperledger/besu/util/FutureUtils.java