Java – what is mongodb’s jdbc driver class name?

In the case of MySQL, like com mysql. jdbc. Like driver, what is the jdbc driver class of mongodb?

In Java code, you can get

MongoClient mongoClient = new MongoClient("localhost");

In the case of JMeter, however, it requires the jdbc driver class name

Solution

You can try to use the following details as a reference @ h_ 419_ 12@

JDBC Driver class name: mongodb. jdbc. MongoDriver

URL format:jdbc:mongo://<\serverName>/<\databaseName>

e.g. url=”jdbc: mongo://ds029847.mongolab.com:29847/tpch ”;

Con = DriverManager. getConnection(url,“dbuser”,“dbuser”);

I hope this will help

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>