简体   繁体   English

Neo4j Jdbc连接池

[英]Neo4j Jdbc connection pool

I am using JDBC driver for Neo4j in my jersey java web application for rest api. 我在我的球衣Java Web应用程序中将Neo4j的JDBC驱动程序用于REST API。 The problem is that it takes a lot of time to open a jdbc Neo4j connection. 问题是打开jdbc Neo4j连接需要花费很多时间。 For every rest api I am opening a neo4j connection and closing it after processing. 对于每个其他api,我都会打开neo4j连接,并在处理后关闭它。

Which is the best connection pool I can use here in this scenario. 在这种情况下,我可以在这里使用最好的连接池。 After googling I found loads of connection pool apis for java. 谷歌搜索后,我发现了Java的连接池api的负载。 Which one do you recommend 你推荐哪一个

Here are the neo4j jdbc drivers https://github.com/neo4j-contrib/neo4j-jdbc#neo4j-jdbc-driver 这是neo4j jdbc驱动程序https://github.com/neo4j-contrib/neo4j-jdbc#neo4j-jdbc-driver

对于即将到来的Neo4j Grails插件,我正在使用tomcat jdbc池,因为它似乎是最近最常用的一个。

Neo4J 3.0 recently released with a new Java Driver . Neo4J 3.0最近发布了新的Java驱动程序 I implemented it in one of my REST APIs by initialising the driver at the start of the application and then using it throughout the app to get sessions and run cypher queries on a remote database. 我通过在应用程序的开头初始化驱动程序,然后在整个应用程序中使用它来获取会话并在远程数据库上运行密码查询,从而在我的REST API中实现了它。

The performance seems to be better compared to the Neo4J JDBC driver. 与Neo4J JDBC驱动程序相比,该性能似乎更好。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM