-
Notifications
You must be signed in to change notification settings - Fork 77
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
[bugfix] add target length validation for each grpc client exection method #1939
[bugfix] add target length validation for each grpc client exection method #1939
Conversation
[CHATOPS:HELP] ChatOps commands.
|
Codecov ReportBase: 29.98% // Head: 32.73% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #1939 +/- ##
==========================================
+ Coverage 29.98% 32.73% +2.75%
==========================================
Files 366 362 -4
Lines 33704 30840 -2864
==========================================
- Hits 10107 10097 -10
+ Misses 23188 20341 -2847
+ Partials 409 402 -7
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
447edbf
to
95c41e3
Compare
Deploying with Cloudflare Pages
|
899ef2d
to
bbc30de
Compare
bbc30de
to
995d3b5
Compare
995d3b5
to
3f0cbc0
Compare
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.
LGTM
3f0cbc0
to
e004aae
Compare
46025c0
to
ee62c81
Compare
ee62c81
to
94cd020
Compare
}, info.Get()) | ||
id, err := s.exists(ctx, uuid) | ||
var attrs trace.Attributes | ||
if err != nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
1529-1546 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:1784-1801
(dupl)
}, info.Get()) | ||
id, err := s.exists(ctx, uuid) | ||
var attrs trace.Attributes | ||
if err != nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
1784-1801 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:1529-1546
(dupl)
if err == nil { | ||
err = errors.ErrObjectIDNotFound(uuid) | ||
vec, err := s.getObject(ctx, uuid) | ||
if err != nil || vec == nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
2004-2049 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:2272-2317
(dupl)
if err == nil { | ||
err = errors.ErrObjectIDNotFound(uuid) | ||
vec, err := s.getObject(ctx, uuid) | ||
if err != nil || vec == nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
2272-2317 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:2004-2049
(dupl)
if err == nil { | ||
err = errors.ErrObjectIDNotFound(id.GetId()) | ||
_, err := s.exists(ctx, uuid) | ||
if err != nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
2900-2947 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:3094-3141
(dupl)
if err == nil { | ||
err = errors.ErrObjectIDNotFound(id.GetId()) | ||
_, err = s.exists(ctx, uuid) | ||
if err != nil { |
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.
🚫 [golangci] reported by reviewdog 🐶
3094-3141 lines are duplicate of pkg/gateway/lb/handler/grpc/handler.go:2900-2947
(dupl)
UnimplementedValdServer: test.fields.UnimplementedValdServer, | ||
} | ||
|
||
gotId, err := s.exists(test.args.ctx, test.args.uuid) |
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.
🚫 [golangci] reported by reviewdog 🐶
ST1003: var gotId should be gotID (stylecheck)
0d91032
to
12b1af3
Compare
12b1af3
to
d95226b
Compare
Profile Report
|
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.
LGTM
…ethod Signed-off-by: kpango <[email protected]>
d95226b
to
9d16336
Compare
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.
LGTM
Signed-off-by: kpango [email protected]
Description:
Vald's gRPC Client is implemented to remove Unhealthy Targets from the connection list and not query the Target in question until the new connection becomes Healthy.
In the event of network total loss, all targets become unhealthy, so Gateways that perform Broadcast and DoMulti instructions do not enter the processing loop and the error is not recognized, making it appear as if the client has succeeded.
As a solution, gRPC Client changed its policy to return the ErrClientConnectionNotFound error when the Target of gRPC Client is zero or the number of times the processing loop is executed is zero, judging that there is no Target.
Versions:
Checklist:
Special notes for your reviewer: