From ec867ac7ce4e4913a8415eda48a7af9fc226097d Mon Sep 17 00:00:00 2001 From: theanarkh Date: Mon, 21 Oct 2024 21:10:53 +0800 Subject: [PATCH] net: add UV_TCP_REUSEPORT for tcp PR-URL: https://github.com/nodejs/node/pull/55408 Refs: https://github.com/libuv/libuv/pull/4407 Reviewed-By: Matteo Collina Reviewed-By: Paolo Insogna Reviewed-By: Luigi Pinca --- doc/api/net.md | 8 ++++ lib/net.js | 22 +++++++--- src/tcp_wrap.cc | 10 +++-- test/common/net.js | 23 +++++++++++ .../test-child-process-net-reuseport.js | 35 ++++++++++++++++ test/parallel/test-cluster-net-reuseport.js | 41 +++++++++++++++++++ test/parallel/test-net-reuseport.js | 26 ++++++++++++ 7 files changed, 156 insertions(+), 9 deletions(-) create mode 100644 test/common/net.js create mode 100644 test/parallel/test-child-process-net-reuseport.js create mode 100644 test/parallel/test-cluster-net-reuseport.js create mode 100644 test/parallel/test-net-reuseport.js diff --git a/doc/api/net.md b/doc/api/net.md index 272705e80edea0..0d78505cc784ec 100644 --- a/doc/api/net.md +++ b/doc/api/net.md @@ -471,6 +471,9 @@ Listening on a file descriptor is not supported on Windows.