[GODRIVER-2056] SRV polling is not spawned because options.MergeClientOptions doesn't handle uri properly Created: 22/Jun/21  Updated: 28/Oct/23  Resolved: 29/Jun/21

Status: Closed
Project: Go Driver
Component/s: Options & Configuration
Affects Version/s: 1.5.3
Fix Version/s: 1.5.4

Type: Bug Priority: Critical - P2
Reporter: Hoonmin Kim Assignee: Isabella Siu (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by GODRIVER-2057 SRV polling is not spawned because op... Closed
Related
related to GODRIVER-908 options.MergeClientOptions doesn't ha... Closed
related to GODRIVER-1507 SRV polling not performed if the URI ... Closed
related to GODRIVER-2069 Add srv polling integration test Closed

 Description   

It seems that SRV polling is not working when using `opts.ApplyURI()` without deprecated deployment options. This made us to restart the application when updating Route53 DNS SRV.

I've found that `pollSRVRecords` is not running because URI is not passed to topology configuration.

So `options.MergeClientOptions` must copy URI like errors to correctly determine the polling requirement.

if t.cfg.uri != "" {
   t.pollingRequired = strings.HasPrefix(t.cfg.uri, "mongodb+srv://")
}



 Comments   
Comment by Isabella Siu (Inactive) [ 29/Jun/21 ]

Hi harebox@gmail.com,

Thanks for reporting this bug! We'll try to get a fix for it into the next patch release.

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