suztomo commented on a change in pull request #39: [MRESOLVER-93] - 
PathRecordingDependencyVisitor to handle 3 cycles
URL: https://github.com/apache/maven-resolver/pull/39#discussion_r315974988
 
 

 ##########
 File path: 
maven-resolver-util/src/main/java/org/eclipse/aether/util/graph/visitor/PathRecordingDependencyVisitor.java
 ##########
 @@ -101,6 +96,7 @@ public boolean visitEnter( DependencyNode node )
     {
         boolean accept = filter == null || filter.accept( node, parents );
 
+        boolean hasDuplicateNodeInParent = parents.contains( node );
 
 Review comment:
   Thank you for the comment. That approach of using visited “set” was the 
cause of this bug.
   
   Multiset (probably via IdentityHashMap<DependencyNode, Integer>) would solve 
the problem and performance. However, the resulting code would be more complex 
than current solution. Until we know there is a performance problem in this 
class, I would choose simpler solution.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to