Skip to content

Worker threads do not close if bind() fails #222

Closed
@GiGurra

Description

@GiGurra

In case the host port (e.g. 80) is occupied on the host (let's say running another web server), you expect a bind error and then the server to close down.

The server's main thread/selector thread does shut down in that scenario, but its worker threads do not.

The reason is that in case of bind() failure, WebSocketServer.run() returns before the try-catch-finally-block which in finally contains shutdown of worker threads.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions