Skip to content

foreach-object Memory usage #12263

@he852100

Description

@he852100

Steps to reproduce

Eventually it was killed

10..60000|foreach-object -ThrottleLimit 15 -parallel {
if(Test-Connection 127.0.0.1 -TcpPort $_ -TimeoutSeconds 1){
$ip listening to port $_
}
}

Expected behavior


Actual behavior

20200406_151832-out


Environment data

PSVersion                      7.1.0-preview.1
PSEdition                      Core
GitCommitId                    7.1.0-preview.1
OS                             Linux 3.10.0-1062.18.1.el7.x86_64 … Platform                       Unix                                PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3                                 SerializationVersion           1.1.0.1                             WSManStackVersion              3.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue-Questionideally support can be provided via other mechanisms, but sometimes folks do open an issue to get aResolution-AnsweredThe question is answered.WG-Cmdlets-Corecmdlets in the Microsoft.PowerShell.Core moduleWG-Engine-Performancecore PowerShell engine, interpreter, and runtime performance

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions