Use BeginAsync/EndAsync methods and remove the use of ThreadPool

Open
#10 21 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
csharp
Domain
networking

Research direction

Start by locating the stream operations that currently use ThreadPool, then compare them with the stream class's BeginAsync/EndAsync methods. Trace all affected call paths and verify that asynchronous behavior and WebSocket operations remain correct after the change; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Description

A good enhancement could be to use the BeginAsync/EndAsync methods of the stream class, and remove all the uses of the ThreadPool. That would make the system faster as it will not have to create threads to make synchronous operations asynchronous. It's a waste of resources.

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.