Q:

Gremlin query execution time issue

I have a gremlin query that finds out shortest path between two two devices(Related to Telecom domain) but both of them have same number of nodes(vertices) but one takes less than 0.5 secs but the other takes more than 5 secs.
What would be the problem behind this?

A:

I'm not completely clear on what you mean by "both of them have same number of nodes(vertices)" but in any meaning I can think of I don't think that you should use that as a basis for equal performance expectations. The real question is how many paths need to be evaluated between the vertices for which you are calculating the shortest path. I would guess that the 5 second traversal simply has to calculate more paths than the 0.5 second one. If you don't expect a significant number of additional paths, then I suppose there could be a problem in your data that needs investigation.

