Skip to content
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: skip callback if xds client reports error #3240

Merged
merged 2 commits into from
Dec 10, 2019

Conversation

menghanl
Copy link
Contributor

@menghanl menghanl commented Dec 10, 2019

Errors will be handled specifically, depending on whether it's a
connection error or other types of errors.

Without this fix, balancer's callback will be called with update,
causing nil panic later.


This change is Reviewable

Copy link
Contributor

@easwars easwars left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @easwars and @menghanl)


xds/internal/balancer/xds_client_test.go, line 208 at r1 (raw file):

	}, attributes.New(xdsinternal.XDSClientID, c),
	)

Should we make sure that the fakeXDS server actually receives the EDS request before invoking the callback?

@easwars
Copy link
Contributor

easwars commented Dec 10, 2019

Also, do you think it would make sense to wait for #3233 and update the test here? Or we can batch up the cleanups, however.

@easwars easwars assigned menghanl and unassigned easwars Dec 10, 2019
Errors will be handled specifically, depending on whether it's a
connection error or other types of errors.

Without this fix, balancer's callback will be called with <nil> update,
causing nil panic later.
Copy link
Contributor Author

@menghanl menghanl left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @easwars and @menghanl)


xds/internal/balancer/xds_client_test.go, line 208 at r1 (raw file):

Previously, easwars (Easwar Swaminathan) wrote…

Should we make sure that the fakeXDS server actually receives the EDS request before invoking the callback?

Done.

Copy link
Contributor

@easwars easwars left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 2 files at r1, 1 of 1 files at r2.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

Copy link
Contributor

@easwars easwars left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@menghanl menghanl merged commit 505c0d6 into grpc:master Dec 10, 2019
@menghanl menghanl deleted the xds_update_err_nil branch December 10, 2019 22:03
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants