Hi guys,
My neo4j crashes when I'm using java API to do batching. The data I have to update is already stored on the server as file. My server is dedicated to neo4j, and I'm just using Java API to call APOC procedures to read those files, after dozens of batch, the program crashes with org.neo4j.driver.v1.exceptions.ServiceUnavailableException: Connection to the database terminated. This can happen due to network instabilities, or due to restarts of the database
It's unlikely due to my java program, because when I logged on my Neo4j server and ran bin/neo4j status, it showed that neo4j is not running. However, when I tried to locate the problem, I didn't get much useful information from log.
The cypher query I'm using is like:
CALL apoc.periodic.iterate(
"CALL apoc.load.json('file:///neo4j/update_type3/updatePropertiesJson41.txt') yield value as row",
"match (n:Entity{eid:row.eid}) CALL apoc.create.setProperties(n, keys(row.properties), [k in keys(row.properties)|row.properties[k]]) yield node return 'node'",{batchSize:1000, parallel:true})
My neo4j.log just showed the batching information, there's no exception, error etc.:
Please notice that the failure of some transactions is expected behavior because I have duplicate eid in my update files, which leads to batch failure when parallel is true
My debug.log showed similar result as neo4j.log, no exception, error etc. as well:
I'm using 3.2.3 enterprise edition.
I suppose the reason for the crash may be the huge workload, but I didn't make it to locate the reason. Any workaround or suggestion will be well appreciated.