websockets-rs / websockets-rs/rust-websocket
Timeout on waiting for incoming WS connections
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 1.6k
- Forks
- 225
- PR merge metrics
- No merged PRs in 30d
Description
I would like to be able to run server.accept() and have it block for a Duration, after which I have an opportunity to perform other logic before continuing my loop.
My purpose is so I can implement a kill switch (an Arc<AtomicBool>, updated elsewhere) and end my thread if it's flipped.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the server.accept() entry point and trace how incoming WebSocket connections are currently waited for. Determine how a Duration-based timeout should return control to the caller so it can inspect the Arc kill switch, then verify that the server loop can continue accepting connections after the timeout.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- networking
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100