I am quering remote db via gremlin from Java like this:
OrientBaseGraph graph = OrientGraphFactory.getNoTx(); \\a bit of pseudocode
in this line
OGremlinHelper.global().setMaxGraphPool(100).create();
String query = "g.E().groupBy{it.weight}{it}.cap.next()";
OCommandGremlin cmd = new OCommandGremlin(query);
Object tt = graph.command(cmd).execute();
Everything is ok and result is correct when query doesn't contain *groupBy *
clause.
I suppose that the problem is in returning a collection of elements except
Vertices or Edges, because the returned Itarable has right number of
elements, corresponding to the groups count or another non-Vertex\edge
elements. But all the elements are *null*s.
E.g. this works:
g.E.filter{ it.weight != 3}.weight[4]
and this does not:
g.E.filter{ it.weight != 3}.weight[1..4]
but the size of returned Iterable is 4, full of nulls. In case of groupBy
query it's the same:
Iterable's size corresponds to real groups count, but contains nulls. So,
it probably is correctly fetched, but incorrectly returned(serialized or
something).
This functionality is very important for me for the following reason. I
know about Rexster and everything works ok with it, except performance in
comparison with builtin gremlin OrientDB support. It's 5 times longer query
fetching time when I use Rexster or Java Gremlin Groovy because of I\O
overhead, that is very large(I profiled, it's all the I\O that make 5x
performance drop). And this is the only way I found to execute Gremlin
queries in server-side. If there are another ways of server-side gremlin
queries fetching, it would be greatly appreciated.
Probably I should create an issue if the bug is confirmed here.
Hope for your help,
Natal Kaplya
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.