Take an SDK that uses the apphost, for example 10.0.300-preview.0.26177.108 that I have installed on my machine. It launches worker nodes as MSBuild.exe, but the code that tries to query for running nodes, when called from ShutdownAllNodes() that doesn't specify executable path or anything
|
private (string expectedProcessName, IList<Process> nodeProcesses) GetPossibleRunningNodes( |
|
string msbuildLocation = null, |
|
NodeMode? expectedNodeMode = null) |
|
{ |
|
bool isNativeHost = msbuildLocation != null && Path.GetFileName(msbuildLocation).Equals(Constants.MSBuildExecutableName, StringComparison.OrdinalIgnoreCase); |
|
string expectedProcessName = Path.GetFileNameWithoutExtension(isNativeHost ? msbuildLocation : (CurrentHost.GetCurrentHost() ?? msbuildLocation)); |
|
|
|
Process[] processes; |
|
try |
|
{ |
|
processes = Process.GetProcessesByName(expectedProcessName); |
tries to query for dotnet, which will not find idle worker nodes.
#13501 worked around an issue related to this for .NET Framework MSBuild, but doesn't resolve the problem described in this bug.
Take an SDK that uses the apphost, for example
10.0.300-preview.0.26177.108that I have installed on my machine. It launches worker nodes asMSBuild.exe, but the code that tries to query for running nodes, when called fromShutdownAllNodes()that doesn't specify executable path or anythingmsbuild/src/Build/BackEnd/Components/Communications/NodeProviderOutOfProcBase.cs
Lines 471 to 481 in fc2a3be
tries to query for
dotnet, which will not find idle worker nodes.#13501 worked around an issue related to this for .NET Framework MSBuild, but doesn't resolve the problem described in this bug.