What mechanism is used to determine the absolute order of vertices in tinkerpop / titan?

When performing the following rounds:

graph.addVertex("a") graph.addVertex("b") graph.addVertex("c") graph.traversal().V().range(0,2) graph.traversal().V().range(2,3) 

What determines the return order of these vertices when using range functionality? Can I bring all three vertices a, b and c back?

+5
source share
1 answer

Without an explicit order().by() you should not expect a guaranteed order.

From the TinkerPop docs:

The result of Traversals is never ordered unless explicitly using order() -step. Thus, never rely on the iteration order between TinkerPop3 releases and even releases (as bypass optimization can change the flow).

+4
source

Source: https://habr.com/ru/post/1239978/


All Articles