You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by sp...@apache.org on 2016/09/28 17:38:28 UTC

[28/41] tinkerpop git commit: simplified the hidden label removal algorithm in StandardVerificationStrategy. Updated CHANGELOG with note about RepeatUnrollStrategy bug fix.

simplified the hidden label removal algorithm in StandardVerificationStrategy. Updated CHANGELOG with note about RepeatUnrollStrategy bug fix.


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/26035e68
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/26035e68
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/26035e68

Branch: refs/heads/TINKERPOP-790
Commit: 26035e68f431efdd80635d8200d9905c6b3e385a
Parents: bb0e22a
Author: Marko A. Rodriguez <ok...@gmail.com>
Authored: Mon Sep 26 12:46:14 2016 -0600
Committer: Marko A. Rodriguez <ok...@gmail.com>
Committed: Tue Sep 27 12:45:49 2016 -0600

----------------------------------------------------------------------
 CHANGELOG.asciidoc                                            | 1 +
 .../strategy/verification/StandardVerificationStrategy.java   | 7 +------
 2 files changed, 2 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/26035e68/CHANGELOG.asciidoc
----------------------------------------------------------------------
diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index cdcad3a..70b2a76 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -26,6 +26,7 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
 TinkerPop 3.2.3 (Release Date: NOT OFFICIALLY RELEASED YET)
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
+* Fixed a bug in `RepeatUnrollStrategy` where inlined traversal did not have strategies applied to it.
 * `TinkerGraphStepStrategy` is now smart about non-`HasContainer` filter steps.
 * Added `TraversalHelper.copyLabels()` for copying (or moving) labels form one step to another.
 * Added `TraversalHelper.applySingleLevelStrategies()` which will apply a subset of strategies but not walk the child tree.

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/26035e68/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/verification/StandardVerificationStrategy.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/verification/StandardVerificationStrategy.java b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/verification/StandardVerificationStrategy.java
index 4f272cc..917fab9 100644
--- a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/verification/StandardVerificationStrategy.java
+++ b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/verification/StandardVerificationStrategy.java
@@ -32,7 +32,6 @@ import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalHelper;
 import org.apache.tinkerpop.gremlin.structure.Graph;
 
 import java.util.Collections;
-import java.util.HashSet;
 import java.util.Set;
 
 /**
@@ -53,13 +52,9 @@ public final class StandardVerificationStrategy extends AbstractTraversalStrateg
         }
 
         for (final Step<?, ?> step : traversal.getSteps()) {
-            final Set<String> hiddenLabels = new HashSet<>();
             for (String label : step.getLabels()) {
                 if (Graph.Hidden.isHidden(label))
-                   hiddenLabels.add(label);
-            }
-            for(final String label : hiddenLabels) {
-                step.removeLabel(label);
+                    step.removeLabel(label);
             }
             if (step instanceof ReducingBarrierStep && step.getTraversal().getParent() instanceof RepeatStep && step.getTraversal().getParent().getGlobalChildren().get(0).getSteps().contains(step))
                 throw new VerificationException("The parent of a reducing barrier can not be repeat()-step: " + step, traversal);