-
Couldn't load subscription status.
- Fork 3k
Description
Description
While profiling Quarkus super heroes we found that mongdb create a huge amount of Threads to handle async I/O (and other operations) - see the attached profiling data
Implementation ideas
I see that https://mongodb.github.io/mongo-java-driver/4.1/apidocs/mongodb-driver-core/com/mongodb/MongoClientSettings.Builder.html#streamFactoryFactory(com.mongodb.connection.StreamFactoryFactory) allows to configure https://mongodb.github.io/mongo-java-driver/4.1/apidocs/mongodb-driver-core/com/mongodb/connection/netty/NettyStreamFactoryFactory.html which could even enable us to re-use the existing Netty/Vertx event loop for mongodb.
In alternative having the chance to size & configure the running thread pool for the mongoDB client would be of great help - unless I've misread how it should be done (@edeandrea as well).