-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hasql version 2.0 (work in progress) #15
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #15 +/- ##
===========================================
- Coverage 87.14% 52.23% -34.91%
===========================================
Files 8 10 +2
Lines 249 268 +19
===========================================
- Hits 217 140 -77
- Misses 27 124 +97
+ Partials 5 4 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bbrodriges Can you please add some examples? It would greatly help with this PR's assessment.
This is an attempt to rethink multiple parts of
hasql
without changing its core mechanics. It is a breaking changes upgrade (hencev2
), although it requires to perform minor code changes for existing end users to adopt this version.This is a Work In Progress pull request as there are not much test for now. Also I want to collect as many feedback as possible to be able to implement all necessary changes before merge.
Notable changes
1.22
due to usage of generics,errors.Join
andslices
package*Node
is now a generic*Node[T]
allowing to use anysql.DB
compatible driver directlyNodeDiscoverer
interface allows to provide dynamic nodes list (e.g. service discovery) oppose to static[]*Node
sliceNodeChecker
is now able to provide any additional information about cluster node (such as latency, replication lag etc.) and this information can be used to pick appropriate nodeMinor changes
context.WithCancel
for more robustClose
method execution