mongo-jdbc-driver
mongo-jdbc-driver copied to clipboard
Test connection too slow
I'm using the newest Datagrip with the newest Mongo driver v1.12. But it's too slow when test connection / open a connection to query, it took great than 17s :( And it's the same when execute a simple query (find with limit 10 item) on a collection >10s :(
I checked Mongo driver other versions and summary in here (test connection - query time):
- v1.12: >17s - >10s
- v1.8 - v1.11: >5s - >2s
- <=v1.73: >2s - >2s
Could you @kornilova203 please check this issue and give me some advices?
@trangiaminh, yes, unfortunately you are right
https://github.com/mongodb-js/mongosh for some reason now runs very slow in Java driver. I'll investigate the issue
@kornilova203 I hope the good news day by day :)
I don't understand yet about https://github.com/mongodb-js/mongosh? It uses Mongo java driver to interact with MongoDB, right?
@trangiaminh,
it's a bit more complicated.
This JDBC driver uses Java mongosh.
Java Mongosh uses Mongo java driver under the hood and knows how to interpret MongoDB commands written in JavaScript like db.collection.find({})
.
Mongo java driver itself cannot run MongoDB commands that are written in JavaScript.
@kornilova203 Currently, only you develop Mongo Driver for DataGrip?
@trangiaminh, yes
@trangiaminh you can also follow an issue https://youtrack.jetbrains.com/issue/DBE-14376 to track progress
Any update on this issue? The latest driver (v1.13) still lags on the initial connection. (takes more than 20s)
At the moment we're investigating this issue. Stay tuned!
I made some optimizations a while ago:
the very first connection will take ~6 seconds but all the subsequent connections should be almost instant.
https://youtrack.jetbrains.com/issue/DBE-14376/Slow-initial-MongoDB-connection#focus=Comments-27-6129076.0-0
I'll close this issue as obsolete