-
Type: Improvement
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.0.2
-
Component/s: Connectivity, Error Handling
-
None
-
Environment:Cloud
So I am running a website on Windows Azure Websites with 2-4 instances connecting to a mongo replica set. My site was originally running on a VM and has migrated to "The Cloud". Since having moved it and upgrading to the 2.0 driver the number of Mongo errors that I have seen has skyrocketed.
I have read many posts and changed the idle timeout to 45 seconds (Azure has upped is socket idle timeout I believe to 4 minutes now...) and have had to implement retry logic and sprinkle it over the whole code base which is very ugly and painful to handle the socket errors that I am seeing.
The SQL Server driver was updated sometime ago to handle these "Transient Connection Errors" https://msdn.microsoft.com/en-us/library/azure/ff394106.aspx.
To make mongo easier to use in the cloud it should have some sort of retry logic/policy built into it. Ideally It would be something that could be set on the IMongoClient with overrides where appropriate.
- is related to
-
CSHARP-2026 All writes retryable support
- Closed
-
CSHARP-2482 Full implementation of retryable reads
- Closed
-
CSHARP-2512 Support Retryable Writes on by Default
- Closed