wonook commented on a change in pull request #232: [NEMO-411] Bug in 
ScheduleGroupPass, OutputTag, DuplicateEdgeGroup
URL: https://github.com/apache/incubator-nemo/pull/232#discussion_r329949669
 
 

 ##########
 File path: common/src/main/java/org/apache/nemo/common/ir/IRDAGChecker.java
 ##########
 @@ -471,9 +472,11 @@ private boolean isConnectedToStreamVertex(final IREdge 
irEdge) {
     return irEdge.getDst() instanceof RelayVertex || irEdge.getSrc() 
instanceof RelayVertex;
   }
 
-  private Map<Optional<String>, List<IREdge>> 
groupOutEdgesByAdditionalOutputTag(final List<IREdge> outEdges) {
+  private final AtomicInteger distinctIntegerForEmptyOutputTag = new 
AtomicInteger(0);
+  private Map<String, List<IREdge>> groupOutEdgesByAdditionalOutputTag(final 
List<IREdge> outEdges) {
     return outEdges.stream().collect(Collectors.groupingBy(
-      (outEdge -> outEdge.getPropertyValue(AdditionalOutputTagProperty.class)),
+      (outEdge -> outEdge.getPropertyValue(AdditionalOutputTagProperty.class)
+        
.orElse(String.valueOf(distinctIntegerForEmptyOutputTag.getAndIncrement()))),
 
 Review comment:
    True. It's needed for loop vertices, where the different edges need 
distinction, while they are left with empty output tags. I'll get the method 
inside the loop checker, instead of implementing it in this method. Thanks for 
pointing out the point that I've overlooked!

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to