public static <T> CompletableFuture<T> scheduleOn(
            final Executor executor,
            final Supplier<CompletableFuture<T>> futureSupplier
    ) {
        return CompletableFuture.supplyAsync(futureSupplier, executor).thenCompose(Function.identity());
    }
Creates a future that schedules a future on the provided executor.

@param executor       executor
@param futureSupplier future factory
@param <T>            future result type
@return future
cloud-core/src/main/java/org/incendo/cloud/util/CompletableFutures.java