255 references to CommunicationsUtilities
Microsoft.Build (158)
BackEnd\BuildManager\BuildParameters.cs (4)
295? CommunicationsUtilities.GetEnvironmentVariables() 375Dictionary<string, string> environment = new(BuildProcessEnvironmentInternal, CommunicationsUtilities.EnvironmentVariableComparer); 386_buildProcessEnvironment = environment.ToFrozenDictionary(CommunicationsUtilities.EnvironmentVariableComparer); 1048_buildProcessEnvironment = CommunicationsUtilities.GetEnvironmentVariables();
BackEnd\BuildManager\CoordinatorClient.DefaultDebugOutput.cs (2)
30CommunicationsUtilities.Trace(message); 38CommunicationsUtilities.Trace(handler.GetFormattedText());
BackEnd\Client\MSBuildClient.cs (30)
230CommunicationsUtilities.Trace($"Executing build with command line '{descriptiveCommandLine}'"); 241CommunicationsUtilities.Trace("Server was not running. Starting server now."); 253CommunicationsUtilities.Trace("Server is busy, falling back to former behavior."); 267CommunicationsUtilities.Trace($"Failed to obtain the current build server state: {ex}"); 268CommunicationsUtilities.Trace($"HResult: {ex.HResult}."); 286CommunicationsUtilities.Trace("Build finished."); 312CommunicationsUtilities.Trace("Trying shutdown server node."); 317CommunicationsUtilities.Trace("No need to shutdown server node for it is not running."); 326CommunicationsUtilities.Trace("Server cannot be shut down for it is not idle."); 333CommunicationsUtilities.Trace("Client cannot connect to idle server to shut it down."); 339CommunicationsUtilities.Trace("Failed to send shutdown command to the server."); 354CommunicationsUtilities.Trace("Wait for server to be not busy - will retry soon..."); 391CommunicationsUtilities.Trace($"MSBuild client error: problem during packet handling occurred: {ex}."); 475CommunicationsUtilities.Trace($"MSBuild client warning: problem during querying console buffer width: {ex}"); 508CommunicationsUtilities.Trace($"Command packet of type '{packet.Type}' sent..."); 512CommunicationsUtilities.Trace($"Failed to send command packet of type '{packet?.Type.ToString() ?? "Unknown"}' to server: {ex}"); 535CommunicationsUtilities.Trace("Another process launching the msbuild server, falling back to former behavior."); 543CommunicationsUtilities.Trace($"Failed to acquire server launch mutex '{serverLaunchMutexName}': {ex}"); 544CommunicationsUtilities.Trace($"HResult: {ex.HResult}."); 552CommunicationsUtilities.Trace("Starting Server..."); 561CommunicationsUtilities.Trace($"Server started with PID: {_launchedServerPid}"); 565CommunicationsUtilities.Trace($"Failed to launch the msbuild server: {ex}"); 613Math.Min(CommunicationsUtilities.NodeConnectionTimeout, TransientServerConnectionTimeoutMilliseconds) 626CommunicationsUtilities.Trace("Sending shutdown command to server."); 671CommunicationsUtilities.GetHandshakeOptions( 684CommunicationsUtilities.Trace("MSBuild client sent cancellation command."); 694CommunicationsUtilities.Trace($"MSBuild client error: packet pump unexpectedly shut down: {packetPump.PacketPumpException}"); 758CommunicationsUtilities.Trace($"Build response received: exit code '{response.ExitCode}', exit type '{response.ExitType}'"); 814CommunicationsUtilities.Trace($"Retrying to connect to server after {sw.ElapsedMilliseconds} ms"); 877CommunicationsUtilities.Trace(
BackEnd\Client\MSBuildClientPacketPump.cs (5)
201CommunicationsUtilities.Trace("Entering read loop."); 234CommunicationsUtilities.Trace("Shutdown message pump thread."); 297CommunicationsUtilities.Trace($"Packet factory failed to receive package. Exception while deserializing packet {packetType}."); 328CommunicationsUtilities.Trace($"Exception occurred in the packet pump: {ex}"); 332CommunicationsUtilities.Trace("Ending read loop.");
BackEnd\Components\Communications\NodeEndpointOutOfProc.cs (1)
37HandshakeOptions handshakeOptions = CommunicationsUtilities.GetHandshakeOptions(
BackEnd\Components\Communications\NodeLauncher.cs (3)
69CommunicationsUtilities.Trace($"Launching node from {nodeLaunchData.MSBuildLocation}"); 138CommunicationsUtilities.Trace($"Successfully launched {exeName} node with PID {process.Id}"); 143CommunicationsUtilities.Trace(
BackEnd\Components\Communications\NodeProviderInProc.cs (1)
381int connectionTimeout = CommunicationsUtilities.NodeConnectionTimeout;
BackEnd\Components\Communications\NodeProviderOutOfProc.cs (4)
72CommunicationsUtilities.Trace($"""MSBUILDNODEHANDSHAKESALT="{Traits.MSBuildNodeHandshakeSalt}", msbuildDirectory="{BuildEnvironmentHelper.Instance.MSBuildToolsDirectory32}", enableNodeReuse={enableNodeReuse}, enableLowPriority={enableLowPriority}"""); 73return new Handshake(CommunicationsUtilities.GetHandshakeOptions(taskHost: false, taskHostParameters: TaskHostParameters.Empty, architectureFlagToSet: XMakeAttributes.GetCurrentMSBuildArchitecture(), nodeReuse: enableNodeReuse, lowPriority: enableLowPriority)); 91Handshake hostHandshake = new(CommunicationsUtilities.GetHandshakeOptions(taskHost: false, taskHostParameters: TaskHostParameters.Empty, architectureFlagToSet: XMakeAttributes.GetCurrentMSBuildArchitecture(), nodeReuse: ComponentHost.BuildParameters.EnableNodeReuse, lowPriority: ComponentHost.BuildParameters.LowPriority)); 103CommunicationsUtilities.Trace($"Starting to acquire {numberOfNodesToCreate} new or existing node(s) to establish nodes from ID {nextNodeId} to {nextNodeId + numberOfNodesToCreate - 1}...");
BackEnd\Components\Communications\NodeProviderOutOfProcBase.cs (45)
199CommunicationsUtilities.Trace($"Shutting down node with pid = {nodeProcess.Id}"); 223CommunicationsUtilities.Trace(nodeId, $"Shutdown response: {shutdown.Reason}. {shutdown.Exception}"); 309CommunicationsUtilities.Trace($"Attempting to connect to {possibleRunningNodesList.Count} existing processes '{expectedProcessName}'..."); 314CommunicationsUtilities.Trace($"Failed to scan for reusable nodes, will launch new nodes instead: {ex}"); 336CommunicationsUtilities.Trace("FAILED TO CONNECT TO A CHILD NODE"); 377CommunicationsUtilities.Trace($"Trying to connect to existing process {expectedProcessName} with id {nodeToReuseId} to establish node {nodeId}..."); 400CommunicationsUtilities.Trace($"Failed to probe existing process with id {nodeToReuseId} while establishing node {nodeId}, skipping it: {ex}"); 407CommunicationsUtilities.Trace($"Successfully connected to existing node {nodeId} which is PID {nodeToReuseId}"); 426CommunicationsUtilities.Trace("Could not connect to existing process, now creating a process..."); 471CommunicationsUtilities.Trace($"Successfully connected to created node {nodeId} which is PID {msbuildProcess.Id}"); 484CommunicationsUtilities.Trace($"Could not connect to node with PID {msbuildProcess.Id}; it has exited with exit code {msbuildProcess.ExitCode}. This can indicate a crash at startup"); 490CommunicationsUtilities.Trace($"Could not connect to node with PID {msbuildProcess.Id}; it has exited with unknown exit code. This can indicate a crash at startup"); 496CommunicationsUtilities.Trace($"Could not connect to node with PID {msbuildProcess.Id}; it is still running. This can occur when two multiprocess builds run in parallel and the other one 'stole' this node"); 653CommunicationsUtilities.Trace($"Filtering {processes.Count} candidate processes by NodeMode {expectedNodeMode} for process name '{expectedProcessName}'"); 663CommunicationsUtilities.Trace($"Skipping process {process.Id} - unable to retrieve command line"); 671CommunicationsUtilities.Trace($"Including process {process.Id} - command line retrieval not supported on this platform"); 679CommunicationsUtilities.Trace($"Including process {process.Id} with matching NodeMode {processNodeMode.Value}"); 684CommunicationsUtilities.Trace( 690CommunicationsUtilities.Trace($"Skipping process {process.Id} - error retrieving command line: {ex.Message}"); 696CommunicationsUtilities.Trace($"Filtered to {filtered.Count} processes matching NodeMode {expectedNodeMode}"); 734CommunicationsUtilities.Trace($"Node reuse threshold is 0, terminating all {nodeCount} nodes"); 741CommunicationsUtilities.Trace($"System-wide node count: {systemWideNodeCount}, threshold: {maxNodesToKeep}, this instance has: {nodeCount} nodes"); 758CommunicationsUtilities.Trace($"Keeping {nodesToKeepInThisInstance} of {nodeCount} nodes in this instance to help meet threshold of {maxNodesToKeep}"); 808CommunicationsUtilities.Trace($"Error counting system-wide nodes with mode {nodeMode}: {ex.Message}"); 901CommunicationsUtilities.Trace($"Attempting connect to PID {nodeProcessId} with pipe {pipeName} with timeout {timeout} ms"); 911CommunicationsUtilities.Trace($"Failed to connect to pipe {pipeName}. {result.ErrorMessage.TrimEnd()}"); 923CommunicationsUtilities.Trace($"Failed to connect to pipe {pipeName}. {e.Message.TrimEnd()}"); 960CommunicationsUtilities.Trace($"Writing handshake part {component.Key} ({component.Value}) to pipe {pipeName}"); 967CommunicationsUtilities.Trace($"Reading handshake from pipe {pipeName}"); 977CommunicationsUtilities.Trace($"Successfully connected to pipe {pipeName}...!"); 1233CommunicationsUtilities.Trace(_nodeId, $"EXCEPTION in RunPacketReadLoopAsync: {e}"); 1266CommunicationsUtilities.Trace(_nodeId, $"EXCEPTION in RunPacketReadLoopAsync (Reading): {e}"); 1301CommunicationsUtilities.Trace(_nodeId, $"Ignoring {packet.Type} after the node send queue closed."); 1325if (_forwardEnvironmentBaseline != null && CommunicationsUtilities.AreDictionariesEquivalent(environment, _forwardEnvironmentBaseline)) 1332_forwardEnvironmentBaseline = new Dictionary<string, string>(environment, CommunicationsUtilities.EnvironmentVariableComparer); 1347if (_forwardGlobalParametersBaseline != null && CommunicationsUtilities.AreDictionariesEquivalent(globalParameters, _forwardGlobalParametersBaseline)) 1460CommunicationsUtilities.Trace(context._nodeId, $"EXCEPTION in SendData: {e}"); 1556CommunicationsUtilities.Trace($"Waiting for node with pid = {_process.Id} to exit"); 1584CommunicationsUtilities.Trace($"Killing node with pid = {_process.Id}"); 1593CommunicationsUtilities.Trace(_nodeId, $"COMMUNICATIONS ERROR (HRC) Node: {_nodeId} Process: {_process.Id} Bytes Read: {bytesRead} Expected: {_headerByte.Length}"); 1598CommunicationsUtilities.Trace(_nodeId, $" Child Process {_process.Id} has exited."); 1602CommunicationsUtilities.Trace(_nodeId, $" Child Process {_process.Id} is still running."); 1607CommunicationsUtilities.Trace(_nodeId, $"Unable to retrieve remote process information. {e}"); 1669CommunicationsUtilities.Trace(_nodeId, $"Bad packet read for packet {packetType} - Expected {packetLength} bytes, got {bytesRead}"); 1688CommunicationsUtilities.Trace(_nodeId, $"EXCEPTION in ReadAndRoutePacket: {e}");
BackEnd\Components\Communications\NodeProviderOutOfProcTaskHost.cs (3)
1143CommunicationsUtilities.Trace($"For a host context of {hostContext}, spawning executable from {nodeLaunchData.MSBuildLocation}."); 1237CommunicationsUtilities.Trace($"For a host context of {hostContext}, using app host from {launchPath}."); 1259CommunicationsUtilities.Trace($"For a host context of {hostContext}, app host not found, falling back to dotnet.exe ({resolvedDotnetHostPath}) hosting {launchPath}.");
BackEnd\Components\Communications\RarNodeLauncher.cs (3)
34CommunicationsUtilities.Trace("Existing RAR node found."); 38CommunicationsUtilities.Trace("Launching RAR node..."); 46CommunicationsUtilities.Trace($"Failed to launch RAR node: {ex}");
BackEnd\Components\Logging\LoggingService.cs (1)
1523Microsoft.Build.Internal.CommunicationsUtilities.Trace($"The logging queue grew from {capacity} to {grown} events.");
BackEnd\Components\RequestBuilder\RequestBuilder.cs (2)
929entryToComplete.RequestConfiguration.SavedEnvironmentVariables = entryToComplete.TaskEnvironment.GetEnvironmentVariables().ToFrozenDictionary(CommunicationsUtilities.EnvironmentVariableComparer); 1457_requestEntry.RequestConfiguration.SavedEnvironmentVariables = _requestEntry.TaskEnvironment.GetEnvironmentVariables().ToFrozenDictionary(CommunicationsUtilities.EnvironmentVariableComparer);
BackEnd\Node\InProcNode.cs (2)
353CommunicationsUtilities.SetEnvironment(_savedEnvironment); 483_savedEnvironment = CommunicationsUtilities.GetEnvironmentVariables();
BackEnd\Node\OutOfProcNode.cs (5)
474CommunicationsUtilities.Trace($"Shutting down with reason: {_shutdownReason}, and exception: {_shutdownException}."); 518CommunicationsUtilities.SetEnvironment(_savedEnvironment); 522CommunicationsUtilities.Trace($"Failed to restore the original environment: {ex}."); 559CommunicationsUtilities.Trace("Shut down complete."); 739_savedEnvironment = CommunicationsUtilities.GetEnvironmentVariables();
BackEnd\Node\OutOfProcServerNode.cs (9)
126CommunicationsUtilities.GetHandshakeOptions(taskHost: false, taskHostParameters: TaskHostParameters.Empty, architectureFlagToSet: XMakeAttributes.GetCurrentMSBuildArchitecture()), 133CommunicationsUtilities.Trace($"Starting new server node with handshake {handshake}"); 288CommunicationsUtilities.Trace($"Shutting down with reason: {_shutdownReason}, and exception: {_shutdownException}."); 299CommunicationsUtilities.Trace("Shut down complete."); 370CommunicationsUtilities.Trace($"Terminating server node due to over-provisioning: {serverNodeCount} server nodes found system-wide."); 381CommunicationsUtilities.Trace("Received request to cancel build running on MSBuild Server. MSBuild server will shutdown."); 405CommunicationsUtilities.Trace($"Building with MSBuild server with command line {command.CommandLine}"); 421CommunicationsUtilities.SetEnvironment(command.BuildProcessEnvironment); 439CommunicationsUtilities.Trace($"ConsoleConfigurationOverride: acceptAnsi={command.ConsoleConfiguration.AcceptAnsiColorCodes}, outputIsScreen={command.ConsoleConfiguration.OutputIsScreen}");
BackEnd\Node\ServerNamedMutex.cs (1)
50CommunicationsUtilities.Trace($"Failed to open mutex '{mutexName}', treating it as not open. Exception: {ex}");
BackEnd\Shared\BuildRequestConfiguration.cs (1)
1066translator.TranslateDictionary(ref _savedEnvironmentVariables, CommunicationsUtilities.EnvironmentVariableComparer);
BackEnd\Shared\BuildResult.cs (4)
717translator.TranslateDictionary(ref _savedEnvironmentVariables, CommunicationsUtilities.EnvironmentVariableComparer); 730translator.TranslateDictionary(ref savedEnvironmentVariables, CommunicationsUtilities.EnvironmentVariableComparer, ref additionalEntries, s_additionalEntriesKeys); 738translator.TranslateDictionary(ref savedEnvironmentVariables, CommunicationsUtilities.EnvironmentVariableComparer, ref additionalEntries, s_additionalEntriesKeys); 740.ToFrozenDictionary(CommunicationsUtilities.EnvironmentVariableComparer); // no-op if already frozen
Evaluation\IntrinsicFunctions.cs (2)
437StringHashingAlgorithm.Legacy => CommunicationsUtilities.GetHashCode(toHash), 495HandshakeOptions desiredContext = CommunicationsUtilities.GetHandshakeOptions(taskHost: true, taskHostParameters: parameters);
Instance\TaskFactories\TaskHostTask.cs (2)
415_requiredContext = CommunicationsUtilities.GetHandshakeOptions( 869CommunicationsUtilities.Trace(_taskHostConnection.NodeId, "The returning build callback no longer has an attached TaskHost handler.");
parent\Shared\NodeEndpointOutOfProcBase.cs (27)
257CommunicationsUtilities.Trace($"Creating pipe '{pipeName}' with buffer size {PipeBufferSize}."); 316CommunicationsUtilities.Trace($"Changing link status from {_status} to {newStatus}"); 403int waitTimeRemaining = Math.Max(0, CommunicationsUtilities.NodeConnectionTimeout - (int)usedWaitTime.TotalMilliseconds); 414CommunicationsUtilities.Trace($"Waiting for connection {waitTimeRemaining} ms..."); 419CommunicationsUtilities.Trace("Connection timed out waiting a host to contact us. Exiting comm thread."); 424CommunicationsUtilities.Trace("Parent started connecting. Reading handshake from parent"); 442byteToAccept: index == 0 ? (byte?)CommunicationsUtilities.handshakeVersion : null, /* this will disconnect a < 16.8 host; it expects leading 00 or F5 or 06. 0x00 is a wildcard */ 448CommunicationsUtilities.Trace($"Handshake failed with error: {result.ErrorMessage}"); 453CommunicationsUtilities.Trace( 480CommunicationsUtilities.Trace($"Sent PacketVersion: {NodePacketTypeExtensions.PacketVersion}"); 483CommunicationsUtilities.Trace("Successfully connected to parent."); 510CommunicationsUtilities.Trace($"Client connection failed but we will wait for another connection. Exception: {e.Message}"); 532CommunicationsUtilities.Trace($"Client connection failed. Exiting comm thread. {e}"); 548CommunicationsUtilities.Trace("Ending read loop"); 605CommunicationsUtilities.Trace($"Handshake for NET Host. Child host {handshakePart} for {component.Key}."); 609CommunicationsUtilities.Trace( 671CommunicationsUtilities.Trace("Entering read loop."); 739CommunicationsUtilities.Trace($"Exception reading from server. {e}"); 753CommunicationsUtilities.Trace("Parent disconnected gracefully."); 760CommunicationsUtilities.Trace("Parent disconnected abruptly."); 766CommunicationsUtilities.Trace($"Incomplete header read from server. {bytesRead} of {headerByte.Length} bytes read"); 788CommunicationsUtilities.Trace($"Invalid packet length {packetLength} received from server. Aborting."); 811CommunicationsUtilities.Trace($"Parent disconnected while reading packet body ({totalBytesRead} of {packetLength} bytes read)."); 822CommunicationsUtilities.Trace($"Exception reading packet body from server. {e}"); 858CommunicationsUtilities.Trace($"Exception while deserializing packet {packetType}: {e}"); 973CommunicationsUtilities.Trace($"Exception while serializing packets: {e}"); 982CommunicationsUtilities.Trace("Disconnecting voluntarily");
Utilities\Utilities.cs (1)
487IDictionary<string, string> environmentVariablesBag = CommunicationsUtilities.GetEnvironmentVariables();
Microsoft.Build.Framework (27)
BackEnd\Handshake.cs (16)
88const int handshakeVersion = (int)CommunicationsUtilities.handshakeVersion; 90CommunicationsUtilities.Trace($"Building handshake for node type {nodeType}, (version {handshakeVersion}): options {options}."); 101int salt = CommunicationsUtilities.GetHashCode($"{handshakeSalt}{toolsDirectory}{changeWaveSalt}"); 111_netTaskHostSaltDriveCaseVariant = CommunicationsUtilities.GetHashCode($"{handshakeSalt}{alternateToolsDirectory}{changeWaveSalt}"); 114CommunicationsUtilities.Trace($"Handshake salt is {handshakeSalt}"); 115CommunicationsUtilities.Trace($"Change wave salt is {changeWaveSalt}"); 116CommunicationsUtilities.Trace($"Tools directory root is {toolsDirectory}"); 180&& receivedSalt == CommunicationsUtilities.AvoidEndOfHandshakeSignal(alternateSalt); 244CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.Options), 245CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.Salt), 246CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionMajor), 247CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionMinor), 248CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionBuild), 249CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionPrivate), 250CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.SessionId)); 256=> CommunicationsUtilities.handshakeVersion;
BackEnd\ServerNodeHandshake.cs (6)
42CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.Options), 43CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.Salt), 44CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionMajor), 45CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionMinor), 46CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionBuild), 47CommunicationsUtilities.AvoidEndOfHandshakeSignal(_handshakeComponents.FileVersionPrivate));
MultiProcessTaskEnvironmentDriver.cs (3)
61return CommunicationsUtilities.GetEnvironmentVariables(); 67CommunicationsUtilities.SetEnvironmentVariable(name, value); 73CommunicationsUtilities.SetEnvironment(newEnvironment);
MultiThreadedTaskEnvironmentDriver.cs (2)
49_environmentVariables = new Dictionary<string, string>(environmentVariables, CommunicationsUtilities.EnvironmentVariableComparer); 61_environmentVariables = new Dictionary<string, string>(variables.Count, CommunicationsUtilities.EnvironmentVariableComparer);
Microsoft.Build.Tasks.Core (26)
AssemblyDependency\Node\OutOfProcRarClient.cs (1)
47CommunicationsUtilities.Trace("Initialized new RAR client.");
AssemblyDependency\Node\OutOfProcRarNode.cs (4)
63CommunicationsUtilities.Trace($"Shutting down with reason: {shutdownReason}"); 67CommunicationsUtilities.Trace($"Shutting down with reason: {shutdownReason}, and exception: {shutdownException}"); 146CommunicationsUtilities.Trace($"{endpoints.Length} RAR endpoints started."); 155CommunicationsUtilities.Trace("All endpoints successfully stopped. Exiting.");
AssemblyDependency\Node\OutOfProcRarNodeEndpoint.cs (7)
47CommunicationsUtilities.Trace($"({_endpointId}) Starting RAR endpoint."); 58CommunicationsUtilities.Trace($"({_endpointId}) RAR endpoint stopped due to cancellation."); 87CommunicationsUtilities.Trace($"({_endpointId}) Received request."); 95CommunicationsUtilities.Trace($"({_endpointId}) Executing RAR..."); 115CommunicationsUtilities.Trace($"({_endpointId}) Completed RAR request."); 122CommunicationsUtilities.Trace($"({_endpointId}) RAR client disconnected."); 132CommunicationsUtilities.Trace($"({_endpointId}) Exception while executing RAR request: {e}");
AssemblyDependency\ResolveAssemblyReference.cs (1)
3841CommunicationsUtilities.Trace($"RAR out-of-proc connection failed, failing back to in-proc. Exception: {ex}");
parent\Shared\NodePipeClient.cs (4)
40CommunicationsUtilities.Trace($"Attempting connect to pipe {PipeName} with timeout {timeout} ms"); 53CommunicationsUtilities.Trace($"Successfully connected to pipe {PipeName}...!"); 83CommunicationsUtilities.Trace($"Writing handshake part {component.Key} ({component.Value}) to pipe {PipeName}"); 90CommunicationsUtilities.Trace($"Reading handshake from pipe {PipeName}");
parent\Shared\NodePipeServer.cs (9)
94int waitTimeRemaining = Math.Max(0, CommunicationsUtilities.NodeConnectionTimeout - (int)usedWaitTime.TotalMilliseconds); 104CommunicationsUtilities.Trace($"Waiting for connection {waitTimeRemaining} ms..."); 115CommunicationsUtilities.Trace("Connection timed out waiting a host to contact us. Exiting comm thread."); 119CommunicationsUtilities.Trace("Parent started connecting. Reading handshake from parent"); 138CommunicationsUtilities.Trace($"Client connection failed but we will wait for another connection. Exception: {e.Message}"); 153CommunicationsUtilities.Trace($"Client connection failed. Exiting comm thread. {e}"); 197_pipeServer.TryReadIntForHandshake(byteToAccept: index == 0 ? CommunicationsUtilities.handshakeVersion : null, 205CommunicationsUtilities.Trace($"Handshake failed. Received {handshakePart} from host not {component.Value}. Probably the host is a different MSBuild build."); 226CommunicationsUtilities.Trace("Successfully connected to parent.");
MSBuild (44)
NodeEndpointOutOfProcTaskHost.cs (1)
36new(CommunicationsUtilities.GetHandshakeOptions(taskHost: true, taskHostParameters: TaskHostParameters.Empty, nodeReuse: _nodeReuse));
OutOfProcTaskHostNode.cs (12)
904_savedEnvironment = CommunicationsUtilities.GetEnvironmentVariables(); 1195CommunicationsUtilities.GetEnvironmentVariables(), 1216CommunicationsUtilities.SetEnvironment(context.SavedEnvironment); 1240CommunicationsUtilities.Trace($"Nested task {taskHostConfiguration.TaskName} dispatched while {_blockedTaskCount} tasks are blocked on callbacks."); 1479CommunicationsUtilities.SetEnvironment(_savedEnvironment); 1483CommunicationsUtilities.Trace($"Failed to restore the sidecar TaskHost environment: {ex}"); 1518CommunicationsUtilities.SetEnvironment(_savedEnvironment); 1701&& CommunicationsUtilities.AreDictionariesEquivalent(taskConfiguration.BuildProcessEnvironment, _lastAppliedConfigEnvironment); 1772IDictionary<string, string> currentEnvironment = CommunicationsUtilities.GetEnvironmentVariables(); 1776CommunicationsUtilities.AreDictionariesEquivalent(currentEnvironment, taskConfiguration.BuildProcessEnvironment); 1806CommunicationsUtilities.SetEnvironment(_savedEnvironment); 1920CommunicationsUtilities.SetEnvironment(updatedEnvironment);
parent\Shared\NodeEndpointOutOfProcBase.cs (27)
257CommunicationsUtilities.Trace($"Creating pipe '{pipeName}' with buffer size {PipeBufferSize}."); 316CommunicationsUtilities.Trace($"Changing link status from {_status} to {newStatus}"); 403int waitTimeRemaining = Math.Max(0, CommunicationsUtilities.NodeConnectionTimeout - (int)usedWaitTime.TotalMilliseconds); 414CommunicationsUtilities.Trace($"Waiting for connection {waitTimeRemaining} ms..."); 419CommunicationsUtilities.Trace("Connection timed out waiting a host to contact us. Exiting comm thread."); 424CommunicationsUtilities.Trace("Parent started connecting. Reading handshake from parent"); 442byteToAccept: index == 0 ? (byte?)CommunicationsUtilities.handshakeVersion : null, /* this will disconnect a < 16.8 host; it expects leading 00 or F5 or 06. 0x00 is a wildcard */ 448CommunicationsUtilities.Trace($"Handshake failed with error: {result.ErrorMessage}"); 453CommunicationsUtilities.Trace( 480CommunicationsUtilities.Trace($"Sent PacketVersion: {NodePacketTypeExtensions.PacketVersion}"); 483CommunicationsUtilities.Trace("Successfully connected to parent."); 510CommunicationsUtilities.Trace($"Client connection failed but we will wait for another connection. Exception: {e.Message}"); 532CommunicationsUtilities.Trace($"Client connection failed. Exiting comm thread. {e}"); 548CommunicationsUtilities.Trace("Ending read loop"); 605CommunicationsUtilities.Trace($"Handshake for NET Host. Child host {handshakePart} for {component.Key}."); 609CommunicationsUtilities.Trace( 671CommunicationsUtilities.Trace("Entering read loop."); 739CommunicationsUtilities.Trace($"Exception reading from server. {e}"); 753CommunicationsUtilities.Trace("Parent disconnected gracefully."); 760CommunicationsUtilities.Trace("Parent disconnected abruptly."); 766CommunicationsUtilities.Trace($"Incomplete header read from server. {bytesRead} of {headerByte.Length} bytes read"); 788CommunicationsUtilities.Trace($"Invalid packet length {packetLength} received from server. Aborting."); 811CommunicationsUtilities.Trace($"Parent disconnected while reading packet body ({totalBytesRead} of {packetLength} bytes read)."); 822CommunicationsUtilities.Trace($"Exception reading packet body from server. {e}"); 858CommunicationsUtilities.Trace($"Exception while deserializing packet {packetType}: {e}"); 973CommunicationsUtilities.Trace($"Exception while serializing packets: {e}"); 982CommunicationsUtilities.Trace("Disconnecting voluntarily");
XMake.cs (4)
540CommunicationsUtilities.Trace($"Unexpected exception during command line parsing. Can not determine if it is allowed to use Server. Fall back to old behavior. Exception: {ex}"); 3229CommunicationsUtilities.Trace($"Invalid node packet version value '{parameters[parameters.Length - 1]}': {ex.Message}"); 3234CommunicationsUtilities.Trace($"Node packet version value '{parameters[parameters.Length - 1]}' out of range: {ex.Message}"); 3783CommunicationsUtilities.Trace($"ResolveProjectPathAgainstLogicalCurrentDirectory: rebased '{projectFile}' to '{rebasedProjectFile}' via $PWD='{logicalCurrentDirectory}'.");