我将嵌入式 Neo4j 用于具有以下规则配置的 JUnit 测试:
@Rule
public Neo4jRule neo4jRule = new Neo4jRule()
.withConfig("dbms.connector.1.enabled", "true")
.withConfig("dbms.connector.1.listen_address", "localhost:4710")
.withConfig("dbms.connector.1.type", "HTTP")
.withConfig("dbms.connector.bolt.enabled", "true")
.withConfig("dbms.connector.bolt.listen_address", ":4711")
.withConfig("apoc.autoIndex.enabled", "true")
.withConfig("ShellSettings.remote_shell_enabled", "true")
.withConfig("ShellSettings.remote_shell_port", "5555")
.withProcedure(apoc.index.FulltextIndex.class)
.withProcedure(apoc.index.FreeTextSearch.class)
.withProcedure(apoc.cypher.Cypher.class);
现在我想在调试(断点设置)期间通过 cypher-shell 进行连接,以便在某个时候查看测试数据库中的实际内容。不幸的是,既没有cypher-shell -a localhost:4711
也没有neo4j-shell -port 5555
得到连接。第一个不返回(仍然挂起),第二个返回Connection refused
。我错过了什么?关于如何建立连接的任何想法?