-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
xds: simplify code handling certain error conditions in the resolver #8123
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #8123 +/- ##
==========================================
- Coverage 82.18% 82.15% -0.03%
==========================================
Files 387 387
Lines 38947 38936 -11
==========================================
- Hits 32007 31988 -19
- Misses 5613 5622 +9
+ Partials 1327 1326 -1
|
@@ -38,8 +41,6 @@ func RouteToMatcher(r *Route) (*CompositeMatcher, error) { | |||
pm = newPathExactMatcher(*r.Path, r.CaseInsensitive) | |||
case r.Prefix != nil: | |||
pm = newPathPrefixMatcher(*r.Prefix, r.CaseInsensitive) | |||
default: | |||
return nil, fmt.Errorf("illegal route: missing path_matcher") |
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.
Should we leave this, with a panic?
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.
Sure. Done here and below.
ead5735
to
a562552
Compare
cds: stop child policies on resource-not-found errors (grpc#8122) xds: simplify code handling certain error conditions in the resolver (grpc#8123) xds, pickfirst: Enable additional addresses in xDS, set new pick_first as default (grpc#8126) github: change test action to cover the legacy pickfirst balancer (grpc#8129) cleanup: replace dial with newclient (grpc#7967) cleanup: replace dial with newclient (grpc#7970) stats/openetelemetry: refactor and make e2e test stats verification deterministic (grpc#8077) xds: introduce simple grpc transport for generic xds clients (grpc#8066) xds: generic xds client common configs re-push comments improve ServerConfig equal easwar review round 1 on documentation easwar comments on docstrings easwar comments round 4 config tests merge with previous pr xds: add lrs client and xDS client interfaces second pass to documentation language change from godoc review dfawley review 2 easwar review 1 changed to decoder struct move authorities under xds client easwar review 2 easwars review 4 ResourceWatcher done and LoadStore stop grpc based transport remove server config extension interface add byte codec dfawley review 1 send and recv tests with byte based test server change to proto based server easwar review 1 easwar review 3 xds: generic xds client ads transport channel
ads: stop child policies on resource-not-found errors (grpc#8122) xds: simplify code handling certain error conditions in the resolver (grpc#8123) xds, pickfirst: Enable additional addresses in xDS, set new pick_first as default (grpc#8126) github: change test action to cover the legacy pickfirst balancer (grpc#8129) cleanup: replace dial with newclient (grpc#7967) cleanup: replace dial with newclient (grpc#7970) stats/openetelemetry: refactor and make e2e test stats verification deterministic (grpc#8077) xds: introduce simple grpc transport for generic xds clients (grpc#8066) xds: generic xds client common configs re-push comments improve ServerConfig equal easwar review round 1 on documentation easwar comments on docstrings easwar comments round 4 config tests merge with previous pr xds: add lrs client and xDS client interfaces second pass to documentation language change from godoc review dfawley review 2 easwar review 1 changed to decoder struct move authorities under xds client easwar review 2 easwars review 4 ResourceWatcher done and LoadStore stop grpc based transport remove server config extension interface add byte codec dfawley review 1 send and recv tests with byte based test server change to proto based server easwar review 1 easwar review 3 xds: generic xds client ads transport channel
Simplifies error handling for a couple of cases:
Simplifying the handling of these cases greatly simplifies the next task, which is to ensure that any error reported by the resolver to the channel must include the xDS node ID. That change will be made in a follow-up PR.
Addresses: #7931
RELEASE NOTES: none