[ https://issues.apache.org/jira/browse/FLINK-4361?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15506106#comment-15506106 ]
ASF GitHub Bot commented on FLINK-4361: --------------------------------------- Github user tillrohrmann commented on a diff in the pull request: https://github.com/apache/flink/pull/2472#discussion_r79565763 --- Diff: flink-runtime/src/main/java/org/apache/flink/runtime/concurrent/impl/FlinkCompletableFuture.java --- @@ -0,0 +1,65 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.flink.runtime.concurrent.impl; + +import org.apache.flink.runtime.concurrent.CompletableFuture; +import org.apache.flink.util.Preconditions; +import scala.concurrent.Promise; + +/** + * Implementation of {@link CompletableFuture} which is backed by {@link Promise}. + * + * @param <T> type of the future's value + */ +public class FlinkCompletableFuture<T> extends FlinkFuture<T> implements CompletableFuture<T> { + + private final Promise<T> promise; + + public FlinkCompletableFuture() { + promise = new scala.concurrent.impl.Promise.DefaultPromise<>(); + scalaFuture = promise.future(); + --- End diff -- Good point, will remove it. > Introduce Flink's own future abstraction > ---------------------------------------- > > Key: FLINK-4361 > URL: https://issues.apache.org/jira/browse/FLINK-4361 > Project: Flink > Issue Type: Sub-task > Components: Distributed Coordination > Reporter: Stephan Ewen > Assignee: Till Rohrmann > > In order to keep the abstraction Scala Independent, we should not rely on > Scala Futures -- This message was sent by Atlassian JIRA (v6.3.4#6332)