StackExchange / StackExchange/StackExchange.Redis

Add warning about WCF service IOCP thread pool usage to Timeouts.md

Open
#2,279 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

📃 documentation
Dominant language
C#
Stars
6.2k
Forks
1.6k
Avg merge
1d 15h
Merged PRs (30d)
43

Description

The WCF service may scale up slowly under load article documents that "WCF uses the .NET CLR IOCP thread pool for executing your WCF service code." As a result, performing synchronous blocking I/O, wait, or maybe even CPU-bound operations in a WCF service can easily lead to IOCP thread pool exhaustion that can result in timeouts for unrelated I/O operations.

The article provides "steps to implement [a] solution that will execute the WCF service on the .NET CLR Worker thread pool" using a new WorkerThreadPoolBehaviorAttribute. I can confirm that this workaround is very effective at resolving the IOCP thread pool exhaustion issues caused by WCF services.

When using WCF services, I would recommend trying the above workaround before manually configuring the IOCP tread pool limits.

I think the above information would be helpful to be added to Timeouts.md, but I am not sure about the best format as the Are you seeing a high number of busyio or busyworker threads in the timeout exception? section is already very long.

Contributor guide

Open the contributing guide

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 with docs/Timeouts.md and review the “Are you seeing a high number of busyio or busyworker threads in the timeout exception?” section, then read the linked Microsoft WCF article. Add a concise warning about WCF IOCP thread-pool exhaustion and link to the WorkerThreadPoolBehaviorAttribute workaround; done when the guidance is clear and fits the existing section.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.