Hi All,
The overall issue is performance. At first when I ram the CYPHER query the result used to show all the Nodes but NO Relationships.
Then I changed the "Initial Node Display" to 2000 from 300 in settings.
Now same query returns 643 nodes and 7443 relationships between 4 different labels of pattern.
This is what I wanted but the only problem is that the graph is very slow. If I try to drag any node or even zoom out, the graph moves after few seconds and sometimes hangs for 5 seconds and then moves.
1. Is this related to OS Browser?
2. Can I improve the performace by changing something in the CYPHER Query?
3. Do I need to change something in the Configuration file like Heap Memory so that the Nodes and Relationships should move around faster?
Please find all the additional details below.
Windows Browser: Chrome
Neo4j Browser version: 3.2.10
Neo4j Server version: [3.4.9]
APOC libraries involved
- apoc.create.vNode
- apoc.create.vRelationship
- apoc.map.groupBy
Below here is the Cypher query I am using.
In this I am collecting/grouping the nodes with some similar properties and their relationships and then creating virtual nodes our of those.
I am not sure if the query is the issue here because I have used another query as well that returns tons of data. Its just that tha data is a huge. (100s and 1000s of nodes and relationships)
MATCH (se:XXLSenderEntity)-[:COUNTERPARTY]->(cp:XXLCounterParty)-[:CUSTODIAN]->(re:XXLReceivingEntity),
(cp:XXLCounterParty)-[:REPAIR_REASON]-(err:XXLRepairReason)
WITH se.senderEntity as sender, cp.counterparty as counter, re.receivingEntity as receiver,err.errorDesc as error, count(*) as count
WITH collect(distinct sender) as senders, collect(distinct counter) as counters, collect(distinct receiver) as receivers,collect(distinct error) as errors, collect([sender, counter, receiver, error,count]) as rels
WITH apoc.map.groupBy([seName IN senders | apoc.create.vNode(['XXLSenderEntity'],{name:seName})], 'name') as senders,
apoc.map.groupBy([cpName IN counters | apoc.create.vNode(['XXLCounterParty'],{name:cpName})], 'name') as counters,
apoc.map.groupBy([reName IN receivers | apoc.create.vNode(['XXLReceivingEntity'],{name:reName})], 'name') as receivers,
apoc.map.groupBy([errName IN errors | apoc.create.vNode(['XXLRepairReason'],{name:errName})], 'name') as errors, rels
UNWIND rels as rel
RETURN senders[rel[0]], counters[rel[1]], apoc.create.vRelationship(senders[rel[0]], 'ALL_COUNTERPARTY', {count:rel[4]}, counters[rel[1]]) as rel, receivers[rel[2]],
apoc.create.vRelationship(counters[rel[1]], 'ALL_RECEIVERS', {count:rel[4]}, receivers[rel[2]]) as rel1, errors[rel[3]],
apoc.create.vRelationship(counters[rel[1]], 'ALL_ERRORS', {count:rel[4]}, errors[rel[3]]) as rel2