GraphDatabaseService Shutdown()没有返回

时间:2014-04-22 14:25:44

标签: java neo4j

我们在RHEL上使用Neo4j2.0.1(jdk 1.7 .. 51) - 我们在一个同步线程上调用GraphDatabaseService.shutDown(),并且此方法永远不会返回或抛出任何异常。

同时尝试访问图表的其他线程在beginTran()

上遇到此异常
org.neo4j.graphdb.TransactionFailureException: Database is currently not available. No blocking components
        at org.neo4j.kernel.InternalAbstractGraphDatabase.beginTx(InternalAbstractGraphDatabase.java:944)
        at org.neo4j.kernel.TransactionBuilderImpl.begin(TransactionBuilderImpl.java:43)
        at net.ahm.graph.EmbeddedDBService.beginTx(EmbeddedDBService.java:275)
        at net.ahm.cm.graph.SummaryForPatientDAO.process(SummaryForPatientDAO.java:29)
        at net.ahm.cm.handlers.admin.GetSummaryPatientInfoMessageHandlerImpl.processAction(GetSummaryPatientInfoMessageHandlerImpl.java:15)
        at net.ahm.cm.handlers.common.BaseCareTeamHandler.doWork(BaseCareTeamHandler.java:46)
        at net.ahm.cm.handlers.common.CareTeamServicesHandler.processService(CareTeamServicesHandler.java:197)
        at net.ahm.cm.thrift.services.common.CareTeamServices$Processor$processService.getResult(CareTeamServices.java:178)
        at net.ahm.cm.thrift.services.common.CareTeamServices$Processor$processService.getResult(CareTeamServices.java:162)
        at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
        at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
        at org.apache.thrift.TMultiplexedProcessor.process(TMultiplexedProcessor.java:123)
        at org.apache.thrift.server.AbstractNonblockingServer$FrameBuffer.invoke(AbstractNonblockingServer.java:516)
        at org.apache.thrift.server.Invocation.run(Invocation.java:18)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:744)

由于shutDown()方法几乎永远会阻塞的原因可能是什么。 请指教。

1 个答案:

答案 0 :(得分:1)

我在几个小时之前遇到过类似的问题,当时我意外地在db.shutdown()个实例上调用GraphDatabaseService并尝试在之后调用同一个实例上的其他方法。也许你可以发布一些代码,以便我们获得更多信息来推理。到目前为止,问题的最可能原因是我所描述的。