You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by ec...@apache.org on 2019/06/27 15:03:20 UTC

[beam] 03/03: Fix wrong encoder in combineGlobally GBK

This is an automated email from the ASF dual-hosted git repository.

echauchot pushed a commit to branch spark-runner_structured-streaming
in repository https://gitbox.apache.org/repos/asf/beam.git

commit dcb3949cdc9f5e8f34227f29ca5bff45df677788
Author: Etienne Chauchot <ec...@apache.org>
AuthorDate: Thu Jun 27 17:00:19 2019 +0200

    Fix wrong encoder in combineGlobally GBK
---
 .../translation/batch/CombineGloballyTranslatorBatch.java               | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/runners/spark/src/main/java/org/apache/beam/runners/spark/structuredstreaming/translation/batch/CombineGloballyTranslatorBatch.java b/runners/spark/src/main/java/org/apache/beam/runners/spark/structuredstreaming/translation/batch/CombineGloballyTranslatorBatch.java
index 9219e3f..1a77fc3 100644
--- a/runners/spark/src/main/java/org/apache/beam/runners/spark/structuredstreaming/translation/batch/CombineGloballyTranslatorBatch.java
+++ b/runners/spark/src/main/java/org/apache/beam/runners/spark/structuredstreaming/translation/batch/CombineGloballyTranslatorBatch.java
@@ -81,7 +81,7 @@ class CombineGloballyTranslatorBatch<InputT, AccumT, OutputT>
     KeyValueGroupedDataset<Integer, Tuple2<Integer, WindowedValue<InputT>>> groupedDataset = keyedDataset
         .groupByKey(
             (MapFunction<Tuple2<Integer, WindowedValue<InputT>>, Integer>) value -> value._1(),
-            EncoderHelpers.windowedValueEncoder());
+            EncoderHelpers.genericEncoder());
 
     Dataset<Tuple2<Integer, Iterable<WindowedValue<OutputT>>>> combinedDataset = groupedDataset
         .agg(new AggregatorCombinerGlobally<>(combineFn, windowingStrategy).toColumn());