[
https://issues.apache.org/jira/browse/TINKERPOP-1248?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15828500#comment-15828500
]
ASF GitHub Bot commented on TINKERPOP-1248:
-------------------------------------------
GitHub user okram opened a pull request:
https://github.com/apache/tinkerpop/pull/538
TINKERPOP-1248: OrderGlobalStep should use local star graph to compute
sorts, prior to reduction.
https://issues.apache.org/jira/browse/TINKERPOP-1248
We now support having the projected data of both `OrderGlobalStep` and
`SampleGlobalStep` being co-located with the `Traverser` via a traverser
wrapper called `ProjectedTraverser`. This allows us to order traversers based
on any projects of the local star graph -- NOT just `PathProcessor.ID`. This
also reduces the complexity of ordering with `by()`-modulation as we don't have
to constantly apply a projection traversal. Finally, this reduces the chances
of problems with serializing the order/sample traversals -- e.g. what if
side-effects are accessed and the traversals in the bi-operators are detached
from the parent traversal.
--- before I VOTE +1, I'm going to see if I can use this same model for
`GroupStep`. If so, huge. If its complicated, will push off for the next tp32/
release.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/apache/tinkerpop TINKERPOP-1248
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/tinkerpop/pull/538.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 #538
----
commit 501e97a1ecb23f76b2fddba8eaed1dba4a5a839e
Author: Marko A. Rodriguez <[email protected]>
Date: 2017-01-18T16:08:24Z
Created OrdertedTraverser which allows us to move beyond the star graph for
OrderGlobalStep by()-projections. Moreover, it reduces the complexity of
ordering as the objects of comparison are already determined. Going to
generalize fully to a ProjectedTraverser which will allow us to do the same for
SampleGlobalStep, DedupGlobalStep, and down the road maintain order even as the
computation is re-distributed to workers.
commit 5045f67f469e163d1363f953672a3f38b4ff2a3f
Author: Marko A. Rodriguez <[email protected]>
Date: 2017-01-18T16:38:21Z
We now have ProjectedTraveser which is a Traverser with List<Object> of
projections. OrderGlobalStep uses this and thus, can order for everything
within the local star graph. Added MultiComparator which is like
ChainedComparator but doesn't contain traversal projections -- just comparators.
commit b2f0c57df6fd9191904213622ae718a0790d7a03
Author: Marko A. Rodriguez <[email protected]>
Date: 2017-01-18T18:07:32Z
Removed a PathProcessor.ID constraint from ComputerVerificationStrategy.
Moreover, sampling and ordering is more efficient as the projected data is
co-located with the traverser in the new ProjectedTraverser wrapper. Going to
leave it at this for tp32/... Moving forward, we can make it so we don't need
to DetachFactory.detach(true) for CollectingBarrierStep by maintaining 'future
data.' Its complicated and I don't want to introduce potential bugs.
commit 91e1f50c8b95d295a86cba6f3c9db7a002664233
Author: Marko A. Rodriguez <[email protected]>
Date: 2017-01-18T18:17:05Z
updated CHANGELOG and tweaked ProjectTraverser variable naming.
----
> OrderGlobalStep should use local star graph to compute sorts, prior to
> reduction.
> ---------------------------------------------------------------------------------
>
> Key: TINKERPOP-1248
> URL: https://issues.apache.org/jira/browse/TINKERPOP-1248
> Project: TinkerPop
> Issue Type: Improvement
> Components: process
> Affects Versions: 3.2.0-incubating
> Reporter: Marko A. Rodriguez
>
> We can get local star graph expressivity from `OrderGlobalStep` in OLAP if we
> emit the object + its `by()`-modulated values. It will yield more data in the
> order, but it will reduce the CPU time as we don't have to call `by()` on
> each order check.
> This ticket will be a bit involved as it will depart from
> `CollectingBarrierStep` semantics and thus, complicate `OrderGlobalSteps`
> implementation...
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)