[CSHARP-2985] Sudden increase in connections Created: 01/Mar/20  Updated: 05/Mar/20  Resolved: 04/Mar/20

Status: Closed
Project: C# Driver
Component/s: None
Affects Version/s: 2.10.2
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Robson Coutinho Assignee: Vincent Kam (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Ubuntu 18.04.2 LTS
c5.large aws instance
DocumentDB 3.6


Attachments: PNG File inscrease-connections.png     PNG File screenshot-1.png    

 Description   

Hi Everyone,

We are using mongodb configured as ReplicaSet, with one primary instance and 3 secondary instances.

Our problem is that sometimes, the number of connections suddenly increases, and from that start several timeout errors, etc.

Could anyone help me understand what may be causing this problem?



 Comments   
Comment by Robson Coutinho [ 05/Mar/20 ]

Hi Vincent,

I appreciate it. Yesterday we discovered a possible cause for these spikes in connections, and it makes sense with what you mentioned. Some areas of our applications are bringing and saving very large documents. There is always an increase in the VolumeWriteIOPS metric before peak connections occur.

Thank you all

Comment by Vincent Kam (Inactive) [ 04/Mar/20 ]

Hi coutinho.robs@gmail.com,

Thanks for reaching out! I wish I could tell you why you are seeing this spike in connections: unfortunately, I was unable to determine why from the information provided.

One possibility that rstam noted is that the spike in connections may be caused by a sudden slowdown in the server: if the server slows down for some reason and the client is under heavy load, that will naturally result in a spike in connections as connections associated with slow queries would not get returned to the connection pool as quickly as they normally would.

As your report does not appear to describe a bug specific to .NET/C# driver and the CSHARP project is for reporting bugs or feature suggestions for the driver, I think the MongoDB Community Forums may be a better place for your question. If you have more information that would indicate that there's a bug in the C#/.NET driver, we would be more than happy to investigate. 
 
Kind regards,
Vincent

Comment by Robson Coutinho [ 01/Mar/20 ]

Connection Pool set to maxConnectionPool = 1000

ConnectionString

mongodb://user:pass@cluster-address:27017,primary-address:27017,secondary-address1:27017,secondary-address2:27017,secondary-address3:27017/?ssl=true&ssl_ca_certs=rds-combined-ca-bundle.pem&replicaSet=rs0

Generated at Wed Feb 07 21:44:02 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.