[
https://issues.apache.org/jira/browse/TINKERPOP-1293?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15278708#comment-15278708
]
ASF GitHub Bot commented on TINKERPOP-1293:
-------------------------------------------
GitHub user okram opened a pull request:
https://github.com/apache/incubator-tinkerpop/pull/310
TINKERPOP-1293: Implement GraphFilterStrategy as a default registration for
GraphComputer
https://issues.apache.org/jira/browse/TINKERPOP-1293
`GraphFilterStrategy` (traversal optimization strategy) will create a graph
filter for the OLAP traversal if one has not already been provided. This is
made possible by `GraphFilterStrategy` analyzing the traversal to determine
which edge directions/labels are being accessed and generating a traversal that
meets that criteria. Along with this, `GraphFilter` has been advanced more
intelligence, more test cases, more JavaDoc, and more helper methods for
`GraphComputer` providers.
`GraphFilterStrategy` is a default `GraphComputer` strategy that is
deactivated by `TinkerGraphComputer` as edge filters are expensive in
`TinkerGraphComputer` given that the entire graph is already loaded into memory
and any filtering requires labeled edges as being filtered (or not).
`mvn clean install`, Spark integration tests passing, and Giraph
integration tests passing thus far...
VOTE +1.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/apache/incubator-tinkerpop TINKERPOP-1293
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/incubator-tinkerpop/pull/310.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #310
----
----
> Implement GraphFilterStrategy as a default registration for GraphComputer
> -------------------------------------------------------------------------
>
> Key: TINKERPOP-1293
> URL: https://issues.apache.org/jira/browse/TINKERPOP-1293
> Project: TinkerPop
> Issue Type: Improvement
> Components: process
> Affects Versions: 3.2.0-incubating
> Reporter: Marko A. Rodriguez
> Assignee: Marko A. Rodriguez
> Fix For: 3.2.1
>
>
> {{GraphFilterStrategy}} would be a {{TraversalStrategy}} for
> {{GraphComputers}}. It will inspect the {{Traversal}} and decide the
> {{computer.vertices(...).edges(...)}} to use.
> Some rules:
> 1. If the traversal is part of an OLAP chain, don't apply strategy.
> 2. If the traversal is persist edges, then don't {{edges(...)}} or
> {{vertices(...)}}.
> 3. If the traversal is persist vertex properties, then don't do
> {{vertices(...)}}.
> Shouldn't be too difficult. Basically looking for:
> 1. {{VertexStep}} labels for edges.
> 2. {{HasStep}} containers for vertices and edges.
> From there, we can get fancy with {{outE().has("stars",gt(4))}}-style
> {{edges(...)}}. However, basic element-label based filtering should be easy.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)