lostintranslation lostintranslation - 2 months ago 20
Node.js Question

Mongodb / Mongoose poolSize recommendation

I am using mongoose in my nodejs application and I am wondering what I should set the poolSize to. I know there is probably no hard and fast rule but maybe based on users and usage there is a general recommendation.

I have left the poolSize left at the default which is 5. At some point I can put the server under load and see how 5 performs. I can then start really bumping it up maybe (100, 500, 1000, etc) to see what happens. Anyone else try this yet and care to share?


This link would help you out. It is difficult to predict the optimal poolsize for MongoDb , i use apache benchmark tests to test the servers performance and response for different values of poolSize and get an approximation for what suits the best for given number of concurrent requests for your server .