47 references to CommunicationsUtilities
MSBuildTaskHost (47)
CommunicationsUtilities.cs (21)
96
const int handshakeVersion = (int)
CommunicationsUtilities
.handshakeVersion;
101
CommunicationsUtilities
.Trace("Building handshake for node type {0}, (version {1}): options {2}.", nodeType, handshakeVersion, options);
104
CommunicationsUtilities
.Trace("Handshake salt is {0}", handshakeSalt);
106
CommunicationsUtilities
.Trace("Tools directory root is {0}", toolsDirectory);
107
salt =
CommunicationsUtilities
.GetHashCode($"{handshakeSalt}{toolsDirectory}");
127
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(options),
128
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(salt),
129
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionMajor),
130
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionMinor),
131
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionBuild),
132
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionPrivate),
133
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(sessionId)
139
public virtual byte? ExpectedVersionInFirstByte =>
CommunicationsUtilities
.handshakeVersion;
160
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(options),
161
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(salt),
162
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionMajor),
163
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionMinor),
164
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionBuild),
165
CommunicationsUtilities
.AvoidEndOfHandshakeSignal(fileVersionPrivate),
501
CommunicationsUtilities
.Trace("Handshake failed on part {0}. Probably the client is a different MSBuild build.", valueRead);
505
CommunicationsUtilities
.Trace("Expected end of handshake signal but received {0}. Probably the host is a different MSBuild build.", valueRead);
NodeEndpointOutOfProcBase.cs (20)
275
CommunicationsUtilities
.Trace("Changing link status from {0} to {1}", _status.ToString(), newStatus.ToString());
366
int waitTimeRemaining = Math.Max(0,
CommunicationsUtilities
.NodeConnectionTimeout - (int)usedWaitTime.TotalMilliseconds);
373
CommunicationsUtilities
.Trace("Waiting for connection {0} ms...", waitTimeRemaining);
382
CommunicationsUtilities
.Trace("Connection timed out waiting a host to contact us. Exiting comm thread.");
387
CommunicationsUtilities
.Trace("Parent started connecting. Reading handshake from parent");
403
byteToAccept: i == 0 ? (byte?)
CommunicationsUtilities
.handshakeVersion : null /* this will disconnect a < 16.8 host; it expects leading 00 or F5 or 06. 0x00 is a wildcard */
412
CommunicationsUtilities
.Trace("Handshake failed. Received {0} from host not {1}. Probably the host is a different MSBuild build.", handshakePart, handshakeComponents[i]);
427
CommunicationsUtilities
.Trace("Successfully connected to parent.");
440
CommunicationsUtilities
.Trace("Handshake failed. Host user is {0} but we were created by {1}.", (clientIdentity == null) ? "<unknown>" : clientIdentity.Name, currentIdentity.Name);
454
CommunicationsUtilities
.Trace("Client connection failed but we will wait for another connection. Exception: {0}", e.Message);
476
CommunicationsUtilities
.Trace("Client connection failed. Exiting comm thread. {0}", e);
493
CommunicationsUtilities
.Trace("Ending read loop");
522
CommunicationsUtilities
.Trace("Entering read loop.");
565
CommunicationsUtilities
.Trace("Exception reading from server. {0}", e);
579
CommunicationsUtilities
.Trace("Parent disconnected gracefully.");
586
CommunicationsUtilities
.Trace("Parent disconnected abruptly.");
592
CommunicationsUtilities
.Trace("Incomplete header read from server. {0} of {1} bytes read", bytesRead, headerByte.Length);
609
CommunicationsUtilities
.Trace("Exception while deserializing packet {0}: {1}", packetType, e);
666
CommunicationsUtilities
.Trace("Exception while serializing packets: {0}", e);
675
CommunicationsUtilities
.Trace("Disconnecting voluntarily");
NodeEndpointOutOfProcTaskHost.cs (1)
33
return new Handshake(
CommunicationsUtilities
.GetHandshakeOptions(taskHost: true));
OutOfProcTaskHostNode.cs (5)
650
_savedEnvironment =
CommunicationsUtilities
.GetEnvironmentVariables();
840
CommunicationsUtilities
.SetEnvironment(_savedEnvironment);
965
IDictionary<string, string> currentEnvironment =
CommunicationsUtilities
.GetEnvironmentVariables();
989
CommunicationsUtilities
.SetEnvironment(_savedEnvironment);
1078
CommunicationsUtilities
.SetEnvironment(updatedEnvironment);