Showing results for 
Search instead for 
Did you mean: 

Head's Up! Site migration is underway. Phase 2: migrate recent content

Save data with spring take too much time

Node Link

Im using neo4j spring data for save node,by using saveall method based on
Im trying to work with batch of 2000 entity per each saveall operation ,for the firsts operations it take aroung to 10 second - and be come more slower - the worst case is 10 min for 2000 entities when in neo4j found 200,000 nodes without any relation

Tnx in advance



Could you please tell me which version of Spring Data Neo4j you are running?

Node Link
        <!-- -->

I expect that you might have a single Node entity class in your Spring Boot solution and that your are using dynamic labels (@Labels())

I expect that saveall uses a merge for each node that it creates. Creating an index on id will solve your performance problemen. Performance now decreases each time that you call saveall, (Also see @Properties(prefix="node",delimeter="_", allowCast=true for creating a dynamic properties collection)

Node is here the Node entity class. (Issue that i see in Neo4j browser is that is shows total count for Node (my entity class) and the totals for each dynamic label,


Creating the index solved the performance issue for me. Saving 5300 Nodes and about 3000 Edges now each time in < 2s. Without the index 10s increasing after each saveall 20s, 35s, ......