Skip to content

Remove unnecessary working field from grpc_ares_ev_driver#25105

Merged
apolcyn merged 1 commit intogrpc:masterfrom
apolcyn:remove_working
Jan 13, 2021
Merged

Remove unnecessary working field from grpc_ares_ev_driver#25105
apolcyn merged 1 commit intogrpc:masterfrom
apolcyn:remove_working

Conversation

@apolcyn
Copy link
Copy Markdown
Contributor

@apolcyn apolcyn commented Jan 6, 2021

Currently there's logic where we:
a) invoke grpc_ares_ev_driver_start_locked when a c-ares resolution begins
b) invoke grpc_ares_ev_driver_start_locked again when the SRV query callback is invoked and the A/AAAA followups go out.

And grpc_ares_ev_driver_start_locked has this working field to apparently guard against its routine from happening again during b), if we don't need it to.

However, all we need is to make sure that grpc_ares_notify_on_event_locked (which is idempotent) gets called again after the A/AAAA SRV followup queries go out. And if the rest of the logic in grpc_ares_ev_driver_start_locked were to somehow run again, it would be buggy due to re-initializing timers.

@apolcyn apolcyn requested a review from markdroth as a code owner January 6, 2021 23:06
@apolcyn apolcyn added lang/core release notes: no Indicates if PR should not be in release notes labels Jan 6, 2021
Copy link
Copy Markdown
Member

@markdroth markdroth left a comment

Choose a reason for hiding this comment

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

Nice simplification!

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

Labels

lang/core release notes: no Indicates if PR should not be in release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants