5 writes to GlobalRequestId
Microsoft.Build (4)
BackEnd\Components\Scheduler\Scheduler.cs (4)
1733newRequest.GlobalRequestId = _nextGlobalRequestId; 2337request.GlobalRequestId = _nextGlobalRequestId++; 2348request.GlobalRequestId = existingRequest.BuildRequest.GlobalRequestId; 2354request.GlobalRequestId = _nextGlobalRequestId++;
Microsoft.Build.Engine.UnitTests (1)
BackEnd\BuildRequestEngine_Tests.cs (1)
507request.GlobalRequestId = _globalRequestId++;
109 references to GlobalRequestId
Microsoft.Build (105)
BackEnd\Components\BuildRequestEngine\BuildRequestEngine.cs (30)
276TraceEngine($"CFB: Shutting down request {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) failed due to exception: {e}"); 295TraceEngine($"CFB: Shutting down request {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) failed due to exception: {e}"); 310TraceEngine($"CFB: Request is now {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) has been deactivated."); 372TraceEngine($"Request {request.GlobalRequestId}({request.ConfigurationId}) (nr {request.NodeRequestId}) received and activated."); 374ErrorUtilities.VerifyThrow(!_requestsByGlobalRequestId.ContainsKey(request.GlobalRequestId), $"Request {request.GlobalRequestId} is already known to the engine."); 375ErrorUtilities.VerifyThrow(_configCache.HasConfiguration(request.ConfigurationId), $"Request {request.GlobalRequestId} refers to configuration {request.ConfigurationId} which is not known to the engine."); 396TraceEngine($"Request {request.GlobalRequestId}({request.ConfigurationId}) (nr {request.NodeRequestId}) retrieved results for configuration {request.ConfigurationId} from node {_componentHost.BuildParameters.NodeId} for transfer."); 434_requestsByGlobalRequestId[request.GlobalRequestId] = entry; 464TraceEngine($"Request {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) is now proceeding from current state {entry.State}."); 485TraceEngine($"Request {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) has retrieved the results for configuration {entry.Request.ConfigurationId} and cached them on node {_componentHost.BuildParameters.NodeId} (UBR)."); 512TraceEngine($"Request {entry.Request.GlobalRequestId}({entry.Request.ConfigurationId}) (nr {entry.Request.NodeRequestId}) is no longer waiting on nr {result.NodeRequestId} (UBR). Results are {result.OverallResult}."); 613TraceEngine($"Request {request.GlobalRequestId} (node request {request.NodeRequestId}) with targets ({string.Join(";", request.Targets)}) satisfied from cache"); 625BuildRequestBlocker blocker = new BuildRequestBlocker(currentEntry.Request.GlobalRequestId, currentEntry.GetActiveTargets(), requestsToIssue.ToArray()); 707TraceEngine($"RRC: Reporting result for request {request.GlobalRequestId}({request.ConfigurationId}) (nr {request.NodeRequestId})."); 792TraceEngine($"ERS: Active request is now {currentEntry.Request.GlobalRequestId}({currentEntry.Request.ConfigurationId}) (nr {currentEntry.Request.NodeRequestId})."); 798TraceEngine($"ERS: Request {currentEntry.Request.GlobalRequestId}({currentEntry.Request.ConfigurationId}) (nr {currentEntry.Request.NodeRequestId}) is marked as complete."); 824TraceEngine($"ERS: Request {completedEntry.Request.GlobalRequestId}({completedEntry.Request.ConfigurationId}) (nr {completedEntry.Request.NodeRequestId}) is being removed from the requests list."); 826_requestsByGlobalRequestId.Remove(completedEntry.Request.GlobalRequestId); 878TraceEngine($"ERS: Request is now {completedEntry.Request.GlobalRequestId}({completedEntry.Request.ConfigurationId}) (nr {completedEntry.Request.NodeRequestId}) has had its builder cleaned up."); 1101if (unsubmittedRequest.BlockingGlobalRequestId == issuingEntry.Request.GlobalRequestId) 1106IssueBuildRequest(new BuildRequestBlocker(issuingEntry.Request.GlobalRequestId, issuingEntry.GetActiveTargets(), YieldAction.Yield)); 1109issuingEntry.WaitForBlockingRequest(issuingEntry.Request.GlobalRequestId); 1115IssueBuildRequest(new BuildRequestBlocker(issuingEntry.Request.GlobalRequestId, issuingEntry.GetActiveTargets(), YieldAction.Reacquire)); 1130issuingEntry.WaitForBlockingRequest(issuingEntry.Request.GlobalRequestId); 1133IssueBuildRequest(new BuildRequestBlocker(issuingEntry.Request.GlobalRequestId)); 1144IssueBuildRequest(new BuildRequestBlocker(issuingEntry.Request.GlobalRequestId, issuingEntry.GetActiveTargets(), unsubmittedRequest.BlockingGlobalRequestId, unsubmittedRequest.BlockingTarget, unsubmittedRequest.PartialBuildResult)); 1248TraceEngine($"Request {issuingEntry.Request.GlobalRequestId}({issuingEntry.Request.ConfigurationId}) (nr {issuingEntry.Request.NodeRequestId}) is waiting on configuration {request.Config.ConfigurationId} (IBR)"); 1283TraceEngine($"Request {newRequest.GlobalRequestId} (node request {newRequest.NodeRequestId}) with targets ({string.Join(",", request.Targets)}) satisfied from cache"); 1340BuildRequestBlocker blocker = new BuildRequestBlocker(issuingEntry.Request.GlobalRequestId, issuingEntry.GetActiveTargets(), requestsToIssue.ToArray());
BackEnd\Components\BuildRequestEngine\BuildRequestEntry.cs (2)
397ErrorUtilities.VerifyThrow(State == BuildRequestEntryState.Waiting, $"Entry must be in the waiting state to be unblocked. Config: {RequestConfiguration.ConfigurationId} State: {State} Request: {Request.GlobalRequestId}"); 398ErrorUtilities.VerifyThrow(_blockingGlobalRequestId != BuildRequest.InvalidGlobalRequestId, $"Entry must be waiting on another request to be unblocked. Config: {RequestConfiguration.ConfigurationId} Request: {Request.GlobalRequestId}");
BackEnd\Components\RequestBuilder\RequestBuilder.cs (5)
234ErrorUtilities.VerifyThrow(_blockType == BlockType.BlockedOnTargetInProgress || _blockType == BlockType.Yielded || (_continueResults != null), $"Unexpected null results for request {_requestEntry.Request.GlobalRequestId} (nr {_requestEntry.Request.NodeRequestId})"); 444RaiseOnBlockedRequest(_requestEntry.Request.GlobalRequestId, null); 453RaiseOnBlockedRequest(_requestEntry.Request.GlobalRequestId, String.Empty); 510RaiseResourceRequest(ResourceRequest.CreateAcquireRequest(_requestEntry.Request.GlobalRequestId, requestedCores, waitForCores)); 544RaiseResourceRequest(ResourceRequest.CreateReleaseRequest(_requestEntry.Request.GlobalRequestId, coresToRelease));
BackEnd\Components\RequestBuilder\TargetBuilder.cs (3)
488_requestEntry.RequestConfiguration.ActivelyBuildingTargets[currentTargetEntry.Name] = _requestEntry.Request.GlobalRequestId; 694if (idOfAlreadyBuildingRequest != _requestEntry.Request.GlobalRequestId) 778if (idOfAlreadyBuildingRequest != _requestEntry.Request.GlobalRequestId)
BackEnd\Components\Scheduler\SchedulableRequest.cs (11)
404ErrorUtilities.VerifyThrow((_state == SchedulableRequestState.Ready) || !_schedulingData.IsRequestScheduled(this), $"Another instance of request {_request.GlobalRequestId} is already scheduled."); 405ErrorUtilities.VerifyThrow(!_schedulingData.IsNodeWorking(nodeId), $"Cannot resume execution of request {_request.GlobalRequestId} because node {nodeId} is already working."); 408ErrorUtilities.VerifyThrow(requiredNodeId == Scheduler.InvalidNodeId || requiredNodeId == nodeId, $"Request {_request.GlobalRequestId} cannot be assigned to node {nodeId} because its configuration is already assigned to node {requiredNodeId}"); 449ErrorUtilities.VerifyThrow(_state == requiredState, $"Request {_request.GlobalRequestId} expected to be in state {requiredState} but state is actually {_state}"); 519SchedulableRequest alternateRequest = _schedulingData.GetBlockedRequestIfAny(blockingRequest.BuildRequest.GlobalRequestId); 534if (requestToEvaluate.BuildRequest.GlobalRequestId == this.BuildRequest.GlobalRequestId) 545requestToEvaluate = _schedulingData.GetBlockedRequestIfAny(requestToEvaluate.BuildRequest.GlobalRequestId); 595if (currentRequest.BuildRequest.GlobalRequestId == blockingRequest.BuildRequest.GlobalRequestId) 680_globalRequestId = request.GlobalRequestId;
BackEnd\Components\Scheduler\Scheduler.cs (27)
394TraceScheduler($"Circular dependency caused by request {ex.Request.GlobalRequestId}({ex.Request.ConfigurationId}) (nr {ex.Request.NodeRequestId}), parent {parentRequest.BuildRequest.GlobalRequestId}({parentRequest.BuildRequest.ConfigurationId}) (nr {parentRequest.BuildRequest.NodeRequestId})"); 407TraceScheduler($"Circular dependency caused by request {ex.Request.GlobalRequestId}({ex.Request.ConfigurationId}) (nr {ex.Request.NodeRequestId}), parent {parentRequest.BuildRequest.GlobalRequestId}({parentRequest.BuildRequest.ConfigurationId}) (nr {parentRequest.BuildRequest.NodeRequestId})"); 446ErrorUtilities.VerifyThrow(result.ParentGlobalRequestId == request.Parent.BuildRequest.GlobalRequestId, "Result's parent doesn't match request's parent."); 483if (unscheduledRequest.BuildRequest.GlobalRequestId == result.GlobalRequestId) 485TraceScheduler($"Request {unscheduledRequest.BuildRequest.GlobalRequestId} (node request {unscheduledRequest.BuildRequest.NodeRequestId}) also satisfied by result."); 1409TraceScheduler($"Chose not to assign request {request.BuildRequest.GlobalRequestId} to node {nodeId} because its count of configurations ({configurationCountsByNode[nodeId]}) exceeds the current limit ({configurationCountLimit})."); 1444TraceScheduler($"Executing request {request.BuildRequest.GlobalRequestId} on node {nodeId} with parent {(request.Parent == null ? -1 : request.Parent.BuildRequest.GlobalRequestId)}"); 1745TraceScheduler($"Created request {newRequest.GlobalRequestId} (node request {newRequest.NodeRequestId}) for transfer of configuration {configuration.ConfigurationId}'s results from node {configuration.ResultsNodeId} to node {parentRequest.AssignedNode}"); 1766if (request.GlobalRequestId == BuildRequest.InvalidGlobalRequestId) 1772TraceScheduler($"Received request {request.GlobalRequestId} (node request {request.NodeRequestId}) with parent {request.ParentGlobalRequestId} from node {nodeForResults} for project {_configCache![request.ConfigurationId].ProjectFullPath} with targets {(request.Targets.Count == 0 ? "default" : string.Join(";", request.Targets))}"); 1780TraceScheduler($"Request {request.GlobalRequestId} (node request {request.NodeRequestId}) satisfied from the cache."); 1876responses.Add(ScheduleResponse.CreateResumeExecutionResponse(parentRequest.AssignedNode, parentRequest.BuildRequest.GlobalRequestId)); 1901TraceScheduler($"Unblocking request {request.BuildRequest.GlobalRequestId} on node {nodeId}"); 1904ScheduleResponse response = ScheduleResponse.CreateResumeExecutionResponse(nodeId, request.BuildRequest.GlobalRequestId); 1941TraceScheduler($"Reporting results for request {request.BuildRequest.GlobalRequestId} with parent {request.BuildRequest.ParentGlobalRequestId} to node {response.NodeId} from cache."); 2106if (blockedRequest.BuildRequest.GlobalRequestId == request.ParentGlobalRequestId) 2117if (executingRequest.BuildRequest.GlobalRequestId == request.ParentGlobalRequestId) 2219TraceScheduler($"Request {request.GlobalRequestId} (node request {request.NodeRequestId}) with targets ({string.Join(";", request.Targets)}) satisfied from cache"); 2334if (request.GlobalRequestId != BuildRequest.InvalidGlobalRequestId 2348request.GlobalRequestId = existingRequest.BuildRequest.GlobalRequestId; 2451int workId = useConfigurations ? buildEvent.Request.BuildRequest.ConfigurationId : buildEvent.Request.BuildRequest.GlobalRequestId; 2647useConfigurations ? request.BuildRequest.ConfigurationId : request.BuildRequest.GlobalRequestId, 2783.BuildRequest.GlobalRequestId) 2984buildRequest.GlobalRequestId,
BackEnd\Components\Scheduler\ScheduleResponse.cs (3)
241return $"Act: {Action} Node: {NodeId} Request: {BuildRequest.GlobalRequestId} Parent {BuildRequest.ParentGlobalRequestId}"; 244return $"Act: {Action} Node: {NodeId} Request: {BuildRequest.GlobalRequestId} Parent {BuildRequest.ParentGlobalRequestId} Configuration: {BuildRequest.ConfigurationId}"; 247return $"Act: {Action} Node: {NodeId} Request: {BuildRequest.GlobalRequestId} Parent {BuildRequest.ParentGlobalRequestId} Configuration: {BuildRequest.ConfigurationId}";
BackEnd\Components\Scheduler\SchedulingData.cs (21)
281ErrorUtilities.VerifyThrow(_buildHierarchy.ContainsKey(parent), $"Parent doesn't exist in build hierarchy for request {request.BuildRequest.GlobalRequestId}"); 297_blockedRequests.Remove(request.BuildRequest.GlobalRequestId); 301_yieldingRequests.Remove(request.BuildRequest.GlobalRequestId); 309_executingRequests.Remove(request.BuildRequest.GlobalRequestId); 314_readyRequests.Remove(request.BuildRequest.GlobalRequestId); 333ErrorUtilities.VerifyThrow(!requestsAssignedToNode.Contains(request), $"Request {request.BuildRequest.GlobalRequestId} is already scheduled to node {request.AssignedNode}"); 357ErrorUtilities.VerifyThrow(!_blockedRequests.ContainsKey(request.BuildRequest.GlobalRequestId), $"Request with global id {request.BuildRequest.GlobalRequestId} is already blocked!"); 358_blockedRequests[request.BuildRequest.GlobalRequestId] = request; 362ErrorUtilities.VerifyThrow(!_yieldingRequests.ContainsKey(request.BuildRequest.GlobalRequestId), $"Request with global id {request.BuildRequest.GlobalRequestId} is already yielded!"); 363_yieldingRequests[request.BuildRequest.GlobalRequestId] = request; 379ErrorUtilities.VerifyThrow(!_executingRequests.ContainsKey(request.BuildRequest.GlobalRequestId), $"Request with global id {request.BuildRequest.GlobalRequestId} is already executing!"); 382_executingRequests[request.BuildRequest.GlobalRequestId] = request; 393ErrorUtilities.VerifyThrow(!_readyRequests.ContainsKey(request.BuildRequest.GlobalRequestId), $"Request with global id {request.BuildRequest.GlobalRequestId} is already ready!"); 394_readyRequests[request.BuildRequest.GlobalRequestId] = request; 402ErrorUtilities.VerifyThrow(!readyRequestsOnNode.Contains(request), $"Request with global id {request.BuildRequest.GlobalRequestId} is already marked as ready on node {request.AssignedNode}"); 407ErrorUtilities.ThrowInternalError($"Request with global id {request.BuildRequest.GlobalRequestId} cannot transition to the Unscheduled state"); 550return InternalGetScheduledRequestByGlobalRequestId(request.BuildRequest.GlobalRequestId) != null;
BackEnd\Shared\BuildRequest.cs (1)
200_parentGlobalRequestId = parentRequest?.GlobalRequestId ?? InvalidGlobalRequestId;
BackEnd\Shared\BuildRequestUnblocker.cs (1)
67_blockedGlobalRequestId = parentRequest.GlobalRequestId;
BackEnd\Shared\BuildResult.cs (1)
238_globalRequestId = request.GlobalRequestId;
Microsoft.Build.Engine.UnitTests (4)
BackEnd\BuildRequest_Tests.cs (2)
130Assert.Equal(request.GlobalRequestId, deserializedRequest.GlobalRequestId);
BackEnd\BuildRequestEngine_Tests.cs (2)
423_engine.UnblockBuildRequest(new BuildRequestUnblocker(request.GlobalRequestId)); 488_engine.UnblockBuildRequest(new BuildRequestUnblocker(request.GlobalRequestId));