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

Fix on epoll-ng when testing in RpcTest shutdown #535

Merged
merged 1 commit into from
Aug 9, 2024

Conversation

Coldwings
Copy link
Collaborator

RpcTest.shutdown case with epoll-ng io engine has chance failing.

Checked all code, found two problems:

  1. EpollNG is possible still got event just after removed watching, makes wake-up notify context not available when waiting thread canceled. Fix by force notify after canceling.
  2. The unit test required background thread have to be execute first, still, during calling sk->shutdown, it have chance to yield thread, makes main thread continue and cause object sk double free. Make it only delete once, and wait for background thread finish by thread join.

@Coldwings Coldwings requested a review from lihuiba August 8, 2024 09:54
@lihuiba lihuiba merged commit e1502a4 into alibaba:main Aug 9, 2024
10 checks passed
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants