[FLINK-2242] [api] Deprecate RemoteCollector interface and implementation This closes #852
Project: http://git-wip-us.apache.org/repos/asf/flink/repo Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/474f9c65 Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/474f9c65 Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/474f9c65 Branch: refs/heads/master Commit: 474f9c65cd4cd11423aac9261ed904378c31f12b Parents: 627f3cb Author: Maximilian Michels <[email protected]> Authored: Fri Jun 19 10:39:27 2015 +0200 Committer: Stephan Ewen <[email protected]> Committed: Tue Jul 7 17:03:05 2015 +0200 ---------------------------------------------------------------------- .../java/org/apache/flink/api/java/io/RemoteCollector.java | 6 ++++++ .../java/org/apache/flink/api/java/io/RemoteCollectorImpl.java | 4 ++++ .../apache/flink/api/java/io/RemoteCollectorOutputFormat.java | 5 +++++ 3 files changed, 15 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flink/blob/474f9c65/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollector.java ---------------------------------------------------------------------- diff --git a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollector.java b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollector.java index 2b3e575..bcfc332 100644 --- a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollector.java +++ b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollector.java @@ -18,6 +18,8 @@ package org.apache.flink.api.java.io; +import org.apache.flink.api.java.DataSet; + import java.rmi.Remote; import java.rmi.RemoteException; @@ -27,7 +29,11 @@ import java.rmi.RemoteException; * * @param <T> * The type of the records the collector will receive + * + * @deprecated Results are retrieved through {@link org.apache.flink.api.common.accumulators.Accumulator} + * and the {@link DataSet#collect()} method respectively. */ +@Deprecated public interface RemoteCollector<T> extends Remote { public void collect(T element) throws RemoteException; http://git-wip-us.apache.org/repos/asf/flink/blob/474f9c65/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorImpl.java ---------------------------------------------------------------------- diff --git a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorImpl.java b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorImpl.java index f30905b..2d080ab 100644 --- a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorImpl.java +++ b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorImpl.java @@ -44,8 +44,12 @@ import org.apache.flink.api.java.operators.DataSink; /** * This class provides a counterpart implementation for the * {@link RemoteCollectorOutputFormat}. + * + * @deprecated Results are retrieved through {@link org.apache.flink.api.common.accumulators.Accumulator} + * and the {@link DataSet#collect()} method respectively. */ +@Deprecated public class RemoteCollectorImpl<T> extends UnicastRemoteObject implements RemoteCollector<T> { http://git-wip-us.apache.org/repos/asf/flink/blob/474f9c65/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorOutputFormat.java ---------------------------------------------------------------------- diff --git a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorOutputFormat.java b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorOutputFormat.java index 06def88..3fe5cef 100644 --- a/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorOutputFormat.java +++ b/flink-java/src/main/java/org/apache/flink/api/java/io/RemoteCollectorOutputFormat.java @@ -26,6 +26,7 @@ import java.rmi.registry.LocateRegistry; import java.rmi.registry.Registry; import org.apache.flink.api.common.io.OutputFormat; +import org.apache.flink.api.java.DataSet; import org.apache.flink.configuration.Configuration; /** @@ -35,7 +36,11 @@ import org.apache.flink.configuration.Configuration; * into an instance of {@link RemoteCollectorOutputFormat}. Further in the * client's VM parameters -Djava.rmi.server.hostname should be set to the own IP * address. + * + * @deprecated Results are retrieved through {@link org.apache.flink.api.common.accumulators.Accumulator} + * and the {@link DataSet#collect()} method respectively. */ +@Deprecated public class RemoteCollectorOutputFormat<T> implements OutputFormat<T> { private static final long serialVersionUID = 1922744224032398102L;
