[ 
https://issues.apache.org/jira/browse/BEAM-6231?focusedWorklogId=184160&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-184160
 ]

ASF GitHub Bot logged work on BEAM-6231:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 11/Jan/19 10:55
            Start Date: 11/Jan/19 10:55
    Worklog Time Spent: 10m 
      Work Description: robertwb commented on pull request #7356: [BEAM-6231] 
Make Dataflow runner harness work with FixedWindow
URL: https://github.com/apache/beam/pull/7356#discussion_r247075386
 
 

 ##########
 File path: 
runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/graph/CreateExecutableStageNodeFunction.java
 ##########
 @@ -195,38 +200,8 @@ public Node apply(MutableNetwork<Node, Edge> input) {
         Iterables.filter(input.nodes(), InstructionOutputNode.class)) {
       InstructionOutput instructionOutput = node.getInstructionOutput();
 
-      // If this is the input PCollection or the output PCollection for an 
ExecutableStage, it's
-      // necessary to check whether the window coder is not a GlobalWindow 
coder.
-      if (isExecutableStageInputPCollection(input, node)
-          || isExecutableStageOutputPCollection(input, node)) {
-        Coder<?> javaCoder =
-            
CloudObjects.coderFromCloudObject(CloudObject.fromSpec(instructionOutput.getCodec()));
-        // For now, Dataflow runner harness only deal with FixedWindow.
-        if (FullWindowedValueCoder.class.isInstance(javaCoder)) {
-          FullWindowedValueCoder<?> windowedValueCoder = 
(FullWindowedValueCoder<?>) javaCoder;
-          Coder<?> windowCoder = windowedValueCoder.getWindowCoder();
-          if (IntervalWindowCoder.class.isInstance(windowCoder)) {
-            fakeWindowingStrategyId = "generatedFixedWindowingStrategy" + 
idGenerator.getId();
-            try {
-              // Since the coder is the only needed from a WindowingStrategy, 
the size field of one
-              // FixedWindows is meaningless here.
-              RunnerApi.MessageWithComponents windowingStrategyProto =
-                  WindowingStrategyTranslation.toMessageProto(
-                      
WindowingStrategy.of(FixedWindows.of(Duration.standardSeconds(1))),
-                      sdkComponents);
-              componentsBuilder.putWindowingStrategies(
-                  fakeWindowingStrategyId, 
windowingStrategyProto.getWindowingStrategy());
-              
componentsBuilder.putAllCoders(windowingStrategyProto.getComponents().getCodersMap());
-              componentsBuilder.putAllEnvironments(
-                  windowingStrategyProto.getComponents().getEnvironmentsMap());
-            } catch (IOException exc) {
-              throw new RuntimeException("Could not convert FixedWindow 
stratey to proto", exc);
-            }
-          }
-        }
-      }
-
       String coderId = "generatedCoder" + idGenerator.getId();
+      String windowingStrategyId = fakeGlobalWindowingStrategyId;
 
 Review comment:
   I would prefer being defensive and leave this unset, then below setting it 
in each of the conditions (including adding a check for global windows and the 
"Coder probably wasn't a java coder" exception clause. This will make it 
clearer when we're right and when we're just sticking something in. 
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 184160)
    Time Spent: 4h 50m  (was: 4h 40m)

> Triage test failures introduced by use_executable_stage_bundle_execution
> ------------------------------------------------------------------------
>
>                 Key: BEAM-6231
>                 URL: https://issues.apache.org/jira/browse/BEAM-6231
>             Project: Beam
>          Issue Type: Test
>          Components: runner-dataflow
>            Reporter: Boyuan Zhang
>            Assignee: Boyuan Zhang
>            Priority: Major
>          Time Spent: 4h 50m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to