beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tg...@apache.org
Subject [3/3] beam git commit: Remove Unused DoFnInfo methods
Date Mon, 22 May 2017 19:35:04 GMT
Remove Unused DoFnInfo methods


Project: http://git-wip-us.apache.org/repos/asf/beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/beam/commit/10357c20
Tree: http://git-wip-us.apache.org/repos/asf/beam/tree/10357c20
Diff: http://git-wip-us.apache.org/repos/asf/beam/diff/10357c20

Branch: refs/heads/master
Commit: 10357c20ba62dab873749f135d23c4dda4033cd7
Parents: e83fcec
Author: Thomas Groh <tgroh@google.com>
Authored: Fri May 19 14:06:12 2017 -0700
Committer: Thomas Groh <tgroh@google.com>
Committed: Mon May 22 12:24:45 2017 -0700

----------------------------------------------------------------------
 .../beam/runners/dataflow/util/DoFnInfo.java    | 25 --------------------
 .../control/ProcessBundleHandlerTest.java       |  2 +-
 2 files changed, 1 insertion(+), 26 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/beam/blob/10357c20/runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/util/DoFnInfo.java
----------------------------------------------------------------------
diff --git a/runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/util/DoFnInfo.java
b/runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/util/DoFnInfo.java
index bd2742f..4a26795 100644
--- a/runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/util/DoFnInfo.java
+++ b/runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/util/DoFnInfo.java
@@ -53,25 +53,6 @@ public class DoFnInfo<InputT, OutputT> implements Serializable {
         doFn, windowingStrategy, sideInputViews, inputCoder, mainOutput, outputMap);
   }
 
-  /** TODO: remove this when Dataflow worker uses the DoFn overload. */
-  @Deprecated
-  @SuppressWarnings("unchecked")
-  public static <InputT, OutputT> DoFnInfo<InputT, OutputT> forFn(
-      Serializable doFn,
-      WindowingStrategy<?, ?> windowingStrategy,
-      Iterable<PCollectionView<?>> sideInputViews,
-      Coder<InputT> inputCoder,
-      long mainOutput,
-      Map<Long, TupleTag<?>> outputMap) {
-    return forFn(
-        (DoFn<InputT, OutputT>) doFn,
-        windowingStrategy,
-        sideInputViews,
-        inputCoder,
-        mainOutput,
-        outputMap);
-  }
-
   public DoFnInfo<InputT, OutputT> withFn(DoFn<InputT, OutputT> newFn) {
     return DoFnInfo.forFn(newFn,
         windowingStrategy,
@@ -96,12 +77,6 @@ public class DoFnInfo<InputT, OutputT> implements Serializable {
     this.outputMap = outputMap;
   }
 
-  /** TODO: remove this when Dataflow worker uses {@link #getDoFn}. */
-  @Deprecated
-  public Serializable getFn() {
-    return doFn;
-  }
-
   /** Returns the embedded function. */
   public DoFn<InputT, OutputT> getDoFn() {
     return doFn;

http://git-wip-us.apache.org/repos/asf/beam/blob/10357c20/sdks/java/harness/src/test/java/org/apache/beam/fn/harness/control/ProcessBundleHandlerTest.java
----------------------------------------------------------------------
diff --git a/sdks/java/harness/src/test/java/org/apache/beam/fn/harness/control/ProcessBundleHandlerTest.java
b/sdks/java/harness/src/test/java/org/apache/beam/fn/harness/control/ProcessBundleHandlerTest.java
index 748ffea..f405728 100644
--- a/sdks/java/harness/src/test/java/org/apache/beam/fn/harness/control/ProcessBundleHandlerTest.java
+++ b/sdks/java/harness/src/test/java/org/apache/beam/fn/harness/control/ProcessBundleHandlerTest.java
@@ -340,7 +340,7 @@ public class ProcessBundleHandlerTest {
         new TestDoFn(),
         WindowingStrategy.globalDefault(),
         ImmutableList.of(),
-        STRING_CODER,
+        StringUtf8Coder.of(),
         mainOutputId,
         ImmutableMap.of(
             mainOutputId, TestDoFn.mainOutput,


Mime
View raw message