amaliujia commented on a change in pull request #16012:
URL: https://github.com/apache/beam/pull/16012#discussion_r762314327



##########
File path: 
sdks/java/testing/nexmark/src/main/java/org/apache/beam/sdk/nexmark/queries/Query13.java
##########
@@ -57,19 +57,8 @@ public Query13(NexmarkConfiguration configuration) {
     final Coder<Event> coder = events.getCoder();
     return events
         .apply("Pair with random key", ParDo.of(new 
AssignShardFn<>(configuration.numKeyBuckets)))
-        .apply(GroupByKey.create())
-        .apply(
-            "ExpandIterable",
-            ParDo.of(
-                new DoFn<KV<Integer, Iterable<Event>>, Event>() {
-                  @ProcessElement
-                  public void processElement(
-                      @Element KV<Integer, Iterable<Event>> element, 
OutputReceiver<Event> r) {
-                    for (Event value : element.getValue()) {
-                      r.output(value);
-                    }
-                  }
-                }))
+        .apply(Reshuffle.of())

Review comment:
       There was a purpose of using GBK not reshuffle.
   
   Reshuffle is composed PTransform that uses non-standard windows, thus it 
lose the chance to hit some optimizations.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to