Closed fuweid closed 2 years ago
The pr https://github.com/containerd/ttrpc-rust/pull/105 fixed the CI problems, please wait for it's merging.
@Tim-Zhang Thanks!
@Tim-Zhang thanks for quick reply. Is it possible to make new release for crate after merge?
@fuweid The version 0.4.16 has been released https://crates.io/crates/ttrpc/0.4.16
The sync/server uses accepted fd as key to maintain the connection and closes the fd before client_handler thread exits. It will cause the deadlock between listen and reaper threads. The timeline is like:
The lowest fd will be returned by accepted. The listener thread will use new connection handler to replace the existing one. Since there is long-running connection for container lifecycle, the reaper thread holds the lock which listener thread is acquiring. It is deadlock.
To fix this issue, we should close fd in the reaper thread to prevent the reuse fd.
Signed-off-by: Wei Fu fuweid89@gmail.com (cherry picked from commit db3639c2669ceb29eee83c2954a97855f7243abb) Signed-off-by: Wei Fu fuweid89@gmail.com