[GODRIVER-976] Connect to passing hosts if one host fails SRV verification Created: 18/Apr/19 Updated: 27/Oct/23 Resolved: 08/Aug/22 |
|
| Status: | Closed |
| Project: | Go Driver |
| Component/s: | Core API |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Isabella Siu (Inactive) | Assignee: | Benji Rewis (Inactive) |
| Resolution: | Works as Designed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
Currently, if one host retrieved from SRV DNS records fails verification we don't connect to any of the returned hosts. According to the spec, we should connect to the ones that pass. |
| Comments |
| Comment by Benji Rewis (Inactive) [ 08/Aug/22 ] |
|
The behavior described is still present in the driver but is correct according to the spec. There are two types of SRV polling that happen within the Go driver. The first is for initial seedlist discovery and is done with the call to ParseHosts here. The second is for mongos discovery and is done with the call to ParseHosts here. The former passes a value of stopOnErr true and the latter passes a value of stopOnErr false. stopOnErr is used in fetchSeedlistFromSRV to determine whether SRV polling should cease upon receiving an error from validateSRVResult. The initial DNS seedlist discovery specification states that we should error on SRV verification failure (stopOnErr should be true):
The polling SRV records for mongos discovery specification states that we should not error on SRV verification failure (stopOnErr should be false):
|
| Comment by Ian Whalen (Inactive) [ 18/Apr/19 ] |
|
isabella.siu to also file a SPEC ticket so we add a prose test for all drivers. |