I am evaluating Neo4j in windows. Since, i need to access Neo4j from a .NET app, I am using the Neo4j Cypher REST API through a .NET client library (http://hg.readify.net/neo4jclient/).
When traversing a reasonably sized graph (About 100,000 nodes), I am facing "Out of memory" issues in the Neo4j java server. Below is the exception that is reported in the REST response. Also, mentioned below is the cypher query that was run. I have tried to increase the JVM heap space with a -Xmx1024m option for the Neo4j server, but that did not help. Would appreciate any other suggestions.
Unhandled Exception: System.ApplicationException: Received an unexpected HTTP st atus when executing the request.
The query was:
START x = node(1213997)
MATCH x-[:BOM*1..5]->n
RETURN 'BOM' AS RelationshipType, n.Number? AS Number, n.Id? AS Id
The response status was: 500 Java heap space
The raw response body was: <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
<title>Error 500 Java heap space</title>
</head>
<body><h2>HTTP ERROR 500</h2>
<p>Problem accessing /db/data/cypher. Reason:
<pre> Java heap space</pre></p><h3>Caused by:</h3><pre>java.lang.OutOfMemoryE
rror: Java heap space
at java.lang.AbstractStringBuilder.<init>(Unknown Source)
at java.lang.StringBuilder.<init>(Unknown Source)
at org.neo4j.server.rest.repr.RepresentationType.<init>(Representa
tionType.java:108)
at org.neo4j.server.rest.repr.Representation.<init>(Representation
.java:73)
at org.neo4j.server.rest.repr.ListRepresentation.<init>(ListRepres
entation.java:36)
at org.neo4j.server.rest.repr.CypherResultRepresentation.data(CypherResu
ltRepresentation.java:64)