|
hasNext() slow for large number of incoming edges
Hi Mathew, I don't know what it does underneath. But if you want to just check about edge existence with hasNext, Can you try with limit 1. g.V(n).inE(e).limit(1).hasNext() Let's see, Amiya
Hi Mathew, I don't know what it does underneath. But if you want to just check about edge existence with hasNext, Can you try with limit 1. g.V(n).inE(e).limit(1).hasNext() Let's see, Amiya
|
By
AMIYA KUMAR SAHOO
· #6369
·
|
|
Indexing Strategies for RDF edges/predicates on Janusgraph
Hi Mathew, Both of the example shows 2 different types of default index. g.V(h).out('mother') - This is example for default vertex-centric indexes per edge label - This will help to traverse specific
Hi Mathew, Both of the example shows 2 different types of default index. g.V(h).out('mother') - This is example for default vertex-centric indexes per edge label - This will help to traverse specific
|
By
AMIYA KUMAR SAHOO
· #6360
·
|
|
Indexing Strategies for RDF edges/predicates on Janusgraph
Hi Mathew, As per the below Note from Janusgraph docs, even if company is having 1k different types of edge related to it, traverse by edge lable will be fast. Such as find employees employedBy (edge
Hi Mathew, As per the below Note from Janusgraph docs, even if company is having 1k different types of edge related to it, traverse by edge lable will be fast. Such as find employees employedBy (edge
|
By
AMIYA KUMAR SAHOO
· #6358
·
|
|
Union Query Optimization
Hi Vinayak, I am not sure how to improve this query further through gremlin. Query can be faster through data model. VCI will be helpful, if you are applying any other filter along with hasLabel and y
Hi Vinayak, I am not sure how to improve this query further through gremlin. Query can be faster through data model. VCI will be helpful, if you are applying any other filter along with hasLabel and y
|
By
AMIYA KUMAR SAHOO
· #5837
·
|
|
Union Query Optimization
Hi Vinayak, You can try below query, it can use index and combine as many traversals you want. g.inject(1). union ( V().has('title', 'V1'). outE().hasLabel('E1').inV().has('title', 'V2'), V().has('tit
Hi Vinayak, You can try below query, it can use index and combine as many traversals you want. g.inject(1). union ( V().has('title', 'V1'). outE().hasLabel('E1').inV().has('title', 'V2'), V().has('tit
|
By
AMIYA KUMAR SAHOO
· #5830
·
|
|
Count Query Optimization
Hi Vinayak, Try below. If it works for you, you can add E2 and D similarly. g.V().has('property1', 'A'). outE().has('property1', 'E').as('e'). inV().has('property1', 'B'). outE().has('property1', 'E1'
Hi Vinayak, Try below. If it works for you, you can add E2 and D similarly. g.V().has('property1', 'A'). outE().has('property1', 'E').as('e'). inV().has('property1', 'B'). outE().has('property1', 'E1'
|
By
AMIYA KUMAR SAHOO
· #5771
·
|
|
Count Query Optimization
Hi Vinayak, Correct vertex count is ( 400332 non-unique, 34693 unique). g.V().has('property1', 'A').aggregate('v'), all the vertex having property1 = A might be getting included in count in your secon
Hi Vinayak, Correct vertex count is ( 400332 non-unique, 34693 unique). g.V().has('property1', 'A').aggregate('v'), all the vertex having property1 = A might be getting included in count in your secon
|
By
AMIYA KUMAR SAHOO
· #5765
·
|
|
Count Query Optimization
Hi Vinayak, May be try below. g.V().has('property1', 'A'). outE().has('property1','E'). where(inV().has('property1', 'B')). fold(). project('edgeCount', 'vertexCount'). by(count(local)). by(unfold().b
Hi Vinayak, May be try below. g.V().has('property1', 'A'). outE().has('property1','E'). where(inV().has('property1', 'B')). fold(). project('edgeCount', 'vertexCount'). by(count(local)). by(unfold().b
|
By
AMIYA KUMAR SAHOO
· #5763
·
|
|
Count Query Optimization
Hi Marc, Vinayak query has a filter on inV property (property1 = B), hence I did not stop at edge itself. If this kind of query is frequent, decision can be made if the same value makes sense to keep
Hi Marc, Vinayak query has a filter on inV property (property1 = B), hence I did not stop at edge itself. If this kind of query is frequent, decision can be made if the same value makes sense to keep
|
By
AMIYA KUMAR SAHOO
· #5725
·
|
|
Count Query Optimization
Hi Vinayak, For query 1. What is the degree centrality of vertex having property A. How much percentage satisfy out edge having property E. If it is small, VCI will help to increase speed for this tra
Hi Vinayak, For query 1. What is the degree centrality of vertex having property A. How much percentage satisfy out edge having property E. If it is small, VCI will help to increase speed for this tra
|
By
AMIYA KUMAR SAHOO
· #5720
·
|