code: public static boolean isCompletedSuccessfully(CompletionStage<?> stage) {
        CompletableFuture<?> future = stage.toCompletableFuture();
        return future.isDone() && !future.isCompletedExceptionally();
     }
docs: Returns if the provided {@link CompletionStage} has already completed normally, that is not due to an exception.
  @param stage stage to check
  @return if the stage is completed normally