[
https://issues.apache.org/jira/browse/TINKERPOP-1781?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
stephen mallette closed TINKERPOP-1781.
---------------------------------------
Resolution: Won't Do
Given the last comment and my understanding of things, I think we should close
this one. I don't think we're going down the path of client side strategy
application. Feel free to re-open if there are some different thoughts here.
> Traversal admin addStep does not update bytecode
> ------------------------------------------------
>
> Key: TINKERPOP-1781
> URL: https://issues.apache.org/jira/browse/TINKERPOP-1781
> Project: TinkerPop
> Issue Type: Improvement
> Components: process
> Affects Versions: 3.3.0, 3.2.6
> Reporter: Ted Wilmes
> Priority: Major
>
> Right now bytecode is constructed at traversal construction time and is not
> updated post-construction when traversal rewriting happens via strategies.
> This works fine in most cases because the traversal is locked post-strategy
> application and will be executed, not serialized out for execution somewhere
> else.
> There are issues when trying to apply client side, pre-serialization
> traversal rewriting (a kind of client-side traversal strategy outside of the
> usual strategy flow). Since a direct call to {{addStep}} circumvents the
> bytecode construction, the bytecode diverges from the rewritten traversal.
> {code}
> gremlin> traversal = g.V().out();null
> ==>null
> gremlin> traversal.getSteps()
> ==>GraphStep(vertex,[])
> ==>VertexStep(OUT,vertex)
> gremlin> traversal.getBytecode()
> ==>[[], [V(), out()]]
> gremlin> TraversalHelper.insertAfterStep(new CountGlobalStep(traversal),
> traversal.getSteps()[1], traversal.asAdmin())
> ==>null
> gremlin> traversal.getSteps()
> ==>GraphStep(vertex,[])
> ==>VertexStep(OUT,vertex)
> ==>CountGlobalStep
> gremlin> traversal.getBytecode()
> ==>[[], [V(), out()]]
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)