Skip to content

Conversation

@glimchb
Copy link
Contributor

@glimchb glimchb commented Oct 25, 2023

Signed-off-by: Boris Glimcher [email protected]

@glimchb glimchb force-pushed the redis-new-client branch 2 times, most recently from 1d7f2d5 to 3423387 Compare October 25, 2023 21:00
@codecov-commenter
Copy link

codecov-commenter commented Oct 25, 2023

Codecov Report

Merging #137 (20b72c5) into master (99127de) will increase coverage by 0.23%.
Report is 15 commits behind head on master.
The diff coverage is 0.00%.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

@@            Coverage Diff             @@
##           master     #137      +/-   ##
==========================================
+ Coverage   64.60%   64.84%   +0.23%     
==========================================
  Files          24       25       +1     
  Lines        2057     2085      +28     
==========================================
+ Hits         1329     1352      +23     
- Misses        601      606       +5     
  Partials      127      127              
Files Coverage Δ
redis/redis.go 70.49% <0.00%> (-6.30%) ⬇️

... and 2 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Owner

@philippgille philippgille left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was looking forward to these constructors to give users maximum flexibility while keeping our library surface area small 👍

Just two comments. And if #130 is merged first, a change to the Godoc here might be required to mention the timeout option (in addition to the codec, as applicable options)

if options.Codec == nil {
options.Codec = DefaultOptions.Codec
}
return &Client{c: rc, codec: options.Codec}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The NewClient currently includes a Ping call to check/establish a connection. Maybe we can do the same here, to minimize NewClient vs NewWithClient differences?

@philippgille
Copy link
Owner

Ah and P.S.: I think we should also extend the tests to make use of a client created with this new constructor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants