Hi, This error usually means you have another process trying to "new EmbeddedGraphDatabaseService()" to the same directory. The only way to have multiple threads talk to the same database is by passing a reference to the database to all threads that want it.
e.g. new Thread() { x = new EmbeddedGraphDatabaseService("/tmp/graph"); }.run(); new Thread() { y = new EmbeddedGraphDatabaseService("/tmp/graph"); }.run(); ** BAD ** x = new EmbeddedGraphDatabaseService("/tmp/graph"); new Thread() { x }.run(); new Thread() { x }.run(); ** GOOD ** Hope that helps, Marko. http://markorodriguez.com On Jul 10, 2011, at 12:41 PM, noppanit wrote: > Thanks for the reply, > > I'm not using Grails plugin, I'm using native embedded neo4j. I'm > redesigning my application just to make sure that I close the database after > use. > > BTW, if I got that error again, would that mean that the database is > corrupted? Is there anyway to restore it? > > -- > View this message in context: > http://neo4j-user-list.438527.n3.nabble.com/What-to-do-with-Unable-to-lock-store-tp3155717p3157185.html > Sent from the Neo4J User List mailing list archive at Nabble.com. > _______________________________________________ > Neo4j mailing list > User@lists.neo4j.org > https://lists.neo4j.org/mailman/listinfo/user _______________________________________________ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user