Repository navigation
Leave the thread pool's minimum alone - #76
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What was wrong
Initialize-ParallelKit, the firstStart-PkProcessand everyInvoke-PkProcessDispatchraised the process-wide thread pool minimum: to at least 128 worker threads, or2 x -MaxConcurrent + 32. That was for the output reads, which used to block pool threads. Since #69 each read has a thread of its own, so the kit no longer needs it, and the minimum is a setting the caller's own code shares.What changed
Initialize-PkThreadPoolis gone, along with its calls fromStart-PkProcessCoreand the dispatcher.Initialize-ParallelKitstill returnsThreadPool(always$true) and still takes-MaxConcurrentProcesses(now unused), so existing scripts keep working.-MaxConcurrentProcesses 8.[PkState]::ThreadPoolRaisedis now unused. It stays for now because removing it is a C# change.How it was tested
SetMinThreadstaken out (minimum 16) against the raised one (128). Five alternating fresh-process rounds per runtime showed no difference:Initialize-ParallelKit, after a firstStart-PkProcessin a fresh process, and after the dispatcher at-MaxConcurrent 100and with a shared budget of 150.🤖 Generated with Claude Code