added example with CompletableFuture