PSParallel
PowerShell module to invoke scriptblocks in parallel runspaces
Install / Use
/learn @powercode/PSParallelREADME
PSParallel
Invoke scriptblocks in parallel runspaces
Installation
Install-Module PSParallel
# ping all machines in a subnet
(1..255).Foreach{"192.168.0.$_"} | Invoke-Parallel { [PSCustomObject] @{IP=$_;Result=ping.exe -4 -a -w 20 $_}}
Variables and functions are captured from the parent session.
Throttling
To control the degree of parallelism, i.e. the number of concurrent runspaces, use the -ThrottleLimit parameter
# process lots of crash dumps
Get-ChildItem -Recurse *.dmp | Invoke-Parallel -ThrottleLimit 64 -ProgressActivity "Processing dumps" {
[PSCustomObject] @{ Dump=$_; Analysis = cdb.exe -z $_.fullname -c '"!analyze -v;q"'
}
The overhead of spinning up new PowerShell classes is non-zero. Invoke-Parallel is useful when you have items with high latency or that is long running.

Contributions
Pull requests and/or suggestions are more than welcome.
Acknowledgements
The idea and the basis for the implementation comes from RamblingCookieMonster. Kudos for that implementation also goes to Boe Prox(@proxb) and Sergei Vorobev(@xvorsx).
Related Skills
node-connect
341.8kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
84.6kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
341.8kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
84.6kCommit, push, and open a PR
