[JAVA-2772] Heartbeat socket settings for MongoClientSettings should have non-infinite read timeout Created: 05/Feb/18  Updated: 28/Oct/23  Resolved: 12/Feb/18

Status: Closed
Project: Java Driver
Component/s: Cluster Management
Affects Version/s: None
Fix Version/s: 3.7.0

Type: Bug Priority: Major - P3
Reporter: Jeffrey Yemin Assignee: Ross Lawley
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

The legacy MongoClient defaults the heartbeat socket settings to a 20 sec connect timeout and a 20 second read timeout.

MongoClientSettings should similarly ensure that the default timeouts are not infinite.

Given the SDAM spec it's possible that MongoClientSettings shouldn't even expose heartbeat socket settings, instead just using the normal socket settings connect timeout. Have to consider backwards compatibility with the existing async MongoClientSettings, and weight that against what API we want to offer going forward.



 Comments   
Comment by Githook User [ 12/Feb/18 ]

Author:

{'email': 'ross.lawley@gmail.com', 'name': 'Ross Lawley', 'username': 'rozza'}

Message: Set default heartbeat socket readtimeout.

JAVA-2772
Branch: master
https://github.com/mongodb/mongo-java-driver/commit/b81eb42ad82b838fe720222517cb9b3a93af3890

Comment by Ross Lawley [ 06/Feb/18 ]

PR: https://github.com/rozza/mongo-java-driver/pull/249

Generated at Thu Feb 08 08:58:02 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.