-
-
Notifications
You must be signed in to change notification settings - Fork 34.2k
Open
Description
For Windows, MacOS, or any Linux distro not specified on the docs page, passing the reusePort=true option for net.server.listen results in server termination.
Is it required that a server terminates in this case, or can there be a graceful fallback for unsupported systems (e.g. default to false on systems that do not support SO_REUSEPORT)?
It appears that there is prior art for platform specific behavior. Could we use a similar pattern to gracefully handle reusePort?
Lines 1852 to 1861 in e28656a
| if (isWindows) { | |
| const instances = NumberParseInt(process.env.NODE_PENDING_PIPE_INSTANCES); | |
| if (!NumberIsNaN(instances)) { | |
| handle.setPendingInstances(instances); | |
| } | |
| } | |
| } else { | |
| handle = new TCP(TCPConstants.SERVER); | |
| isTCP = true; | |
| } |
nickhudkins
Metadata
Metadata
Assignees
Labels
No labels