sta / sta/websocket-sharp

multi-thread support?

Open
#338 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

currently each Send() will cause a lock to _forSend, so the data will transmit like this:

data1:frg1
data1:frg2
data2:frg1
data2:frg2
...

if multi-thread implemented, it should look like this:

data1:frg1
data2:frg1
data2:frg2
data1:frg2

but it may cause messages mis-ordered, maybe I should customize this protocol somehow.

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.

Research direction

Start by tracing Send() and the _forSend lock to understand the current serialization behavior. The issue does not define whether message or fragment ordering should be guaranteed, so first clarify the protocol and concurrency requirements. Done would require an agreed ordering model and corresponding multi-threaded behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
networking
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.