Recommended configuration for MongoDB C# hosted on Azure app service

I’m aware of limits on azure app services, like max outbound tcp connections.

Are there recommended configuration settings for using the Mongo C# driver in a busy application hosted on an azure app service. Things like - min/max connection pool size, timeouts, wait queue multiple (although this seems set for deprecation)

Hi @Paul_Allington, thanks for your question!

There’s nothing specific to the driver that needs to be addressed; the limits on Azure App Services still apply.

One thing that is worth mentioning is to instantiate your MongoClient as a singleton in your application, as recommended by the docs. In this way, you can take advantage of connection pooling.

I have it as a singleton yeah. Occasionally we get a big spike in waitqueuefullexceptions. So I wondered what defaults are recommended based on the limits in azure. Like what should be the max connection pool size and the timeouts?