[GODRIVER-94] Change readpref.Primary() return constant Created: 27/Sep/17  Updated: 28/Oct/23  Resolved: 05/Mar/18

Status: Closed
Project: Go Driver
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Samuel Rossi (Inactive) Assignee: Samuel Rossi (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: GODRIVER Beta UX

 Description   

Given that the value returned by `readpref.Primary()` is always the same, we should create a constant for it and have that returned rather than doing a new allocation for each call.



 Comments   
Comment by Githook User [ 05/Mar/18 ]

Author:

{'email': 'saghmrossi@gmail.com', 'name': 'Saghm Rossi', 'username': 'saghm'}

Message: GODRIVER-94 Change readpref.Primary() to return constant

Change-Id: I8ab5cd88083a981f43890b0c38977889005e923c
Branch: master
https://github.com/mongodb/mongo-go-driver/commit/18258e579f8238a91849ab6574053f2cce598205

Comment by Samuel Rossi (Inactive) [ 05/Mar/18 ]

Code review url: https://review.gerrithub.io/c/402608/

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