Slow timeout (up to 25 minutes) if the server goes away

Open
#689 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
csharp
Domain
networking

Research direction

Start by reproducing the Android client behavior when the Windows host disappears, focusing on the interaction between WaitTime, receive timeouts, and the eventual SocketException. Done means the failure is detected within a defined bound or the supported mitigation is clearly documented and covered by a test.

Written by the indexing model from the issue text.

Description

I'm using ws-sharp in a background Xamarin service on Android connecting to a Windows PC (also ws-sharp) but if the Windows PC goes away (crash, etc) without telling the client to disconnect it'll take up to 25 minutes before it eventually throws a SocketException and "No route to host"

I've got WaitTime set to 1 minute, but is there any way to entirely mitigate this? It's a receive timeout rather than a send timeout

Dominant language
C#
Stars
6.1k
Forks
1.7k
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from sta/websocket-sharp

All issues in sta/websocket-sharp

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.