Succinct way to get shortest paths


Hi there,
I got following query for shortest path from germlindocs

gremlin> g.v(1).out.loop(1){ != “5” && it.loops < 6}.path
==>[v[1], v[4], v[5]]

But it seems cayley does not fully support Germlin grammar…that query doesn’t work
Anyone can shed some light here?
Thanks a ton!

let me put this way, is there a way to check if 2 objects are connected?
same question was post by someone else!msg/cayley-users/Ml4X9FZsQcQ/BgCZNkA4H4IJ

Hi @rogeronline,

There is no way to check it directly right now.
The barakmich/transitive_closure branch implements functionality necessary for “loop” command in Gremlin, but it is exposed to Golang only.
You may also try to achieve the same result with manual iteration, as described in the mailing list.