You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tinkerpop.apache.org by "Florian Hockmann (JIRA)" <ji...@apache.org> on 2018/12/26 13:34:00 UTC

[jira] [Commented] (TINKERPOP-1964) Gremlin.Net: Expose Strategies in GraphTraversal

    [ https://issues.apache.org/jira/browse/TINKERPOP-1964?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16729038#comment-16729038 ] 

Florian Hockmann commented on TINKERPOP-1964:
---------------------------------------------

The easiest approach to solve this would be to just make the {{get}} property {{DefaultTraversal.TraversalStrategies}} public, but that would only include the {{RemoteStrategy}} as all other strategies are only sent to the server as part of the {{Bytecode}}.

We could also extend the source step {{WithStrategies()}} to add the strategies also to its {{TravesalStrategies}} which would still be pretty easy to implement. (+ Exclusion of strategies via {{WithoutStrategies()}})

However, a traversal usually already includes some default strategies that are not available directly via remote. For example, when I try the example from the description in the Gremlin Console with TinkerGraph, then I get:
{code:java}
g.V().has("name", "jorge").asAdmin().getStrategies()
==>strategies[ConnectiveStrategy, IncidentToAdjacentStrategy, MatchPredicateStrategy, FilterRankingStrategy, InlineFilterStrategy, AdjacentToIncidentStrategy, RepeatUnrollStrategy, CountStrategy, PathRetractionStrategy, LazyBarrierStrategy, TinkerGraphCountStrategy, TinkerGraphStepStrategy, ProfileStrategy, StandardVerificationStrategy]
 {code}
I guess if we really want to expose all strategies that will be applied to their traversal, then we need to retrieve these default strategies, add configured strategies by the user locally and then exclude strategies given to {{WithoutStrategies()}}. But I'm not sure whether we really want to do that.

What do you think [~jorgebg]? Was your intention with this ticket only to show the strategies configured locally in the GLV?

> Gremlin.Net: Expose Strategies in GraphTraversal
> ------------------------------------------------
>
>                 Key: TINKERPOP-1964
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1964
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: dotnet
>            Reporter: Jorge Bay
>            Priority: Major
>
> We should provide a way to access the strategies from the traversal.
> This is currently possible in java but not on the .NET GLV:
> {code:java}
> GraphTraversal<Vertex, Vertex> traversal = g.V().has("name", "jorge");
> TraversalStrategies = traversal.asAdmin().getStrategies();
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)