I ran a query to match all 'diamond patterns' on the Epinions1 dataset 
<https://snap.stanford.edu/data/soc-Epinions1.html> (75877 nodes/ 508836 
edges) for an academic project and found that Neo4j needs >100g of heap 
during the evaluation. The query I used was,


MATCH (a:User)-[:TRUSTS]->(b:User)-[:TRUSTS]->(c:User), (c)-[:TRUSTS]->(a)
WITH count(*) AS cnt
RETURN cnt;


<https://lh3.googleusercontent.com/-RQIVSMvrgFo/WGxGcafFogI/AAAAAAAAAio/98cmtz8j4fw6IyQswY6yi1cY3slJ_CxqQCLcB/s1600/neo4j_query_plan_epinions_diamond.png>


The count I got back was 286,371,276.

The heap size seems too large given the number of intermediate results in the 
query plan estimates. 

Can the memory usage be because the final results are being stored in memory 
too? How big are intermediate/ final record row objects on average?


Thanks,

Chathura

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" 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.

Reply via email to