88 references to SchedulableRequestState
Microsoft.Build (88)
BackEnd\Components\Scheduler\SchedulableRequest.cs (51)
71private SchedulableRequestState _state; 122private Dictionary<SchedulableRequestState, ScheduleTimeRecord> _timeRecords; 140_timeRecords = new Dictionary<SchedulableRequestState, ScheduleTimeRecord>(5); 141_timeRecords[SchedulableRequestState.Unscheduled] = new ScheduleTimeRecord(); 142_timeRecords[SchedulableRequestState.Blocked] = new ScheduleTimeRecord(); 143_timeRecords[SchedulableRequestState.Yielding] = new ScheduleTimeRecord(); 144_timeRecords[SchedulableRequestState.Executing] = new ScheduleTimeRecord(); 145_timeRecords[SchedulableRequestState.Ready] = new ScheduleTimeRecord(); 146_timeRecords[SchedulableRequestState.Completed] = new ScheduleTimeRecord(); 148ChangeToState(SchedulableRequestState.Unscheduled); 154public SchedulableRequestState State 190VerifyOneOfStates([SchedulableRequestState.Yielding, SchedulableRequestState.Blocked, SchedulableRequestState.Executing]); 303public TimeSpan GetTimeSpentInState(SchedulableRequestState desiredState) 313VerifyState(SchedulableRequestState.Executing); 316ChangeToState(SchedulableRequestState.Yielding); 324VerifyState(SchedulableRequestState.Yielding); 326ChangeToState(SchedulableRequestState.Ready); 337VerifyOneOfStates([SchedulableRequestState.Blocked, SchedulableRequestState.Executing]); 353blockingRequest.VerifyOneOfStates([SchedulableRequestState.Yielding, SchedulableRequestState.Blocked, SchedulableRequestState.Ready, SchedulableRequestState.Unscheduled]); 366ChangeToState(SchedulableRequestState.Blocked); 374VerifyOneOfStates([SchedulableRequestState.Blocked, SchedulableRequestState.Unscheduled]); 387VerifyOneOfStates([SchedulableRequestState.Blocked, SchedulableRequestState.Unscheduled]); 403VerifyOneOfStates([SchedulableRequestState.Ready, SchedulableRequestState.Unscheduled]); 404ErrorUtilities.VerifyThrow((_state == SchedulableRequestState.Ready) || !_schedulingData.IsRequestScheduled(this), "Another instance of request {0} is already scheduled.", _request.GlobalRequestId); 411ChangeToState(SchedulableRequestState.Executing); 419VerifyOneOfStates([SchedulableRequestState.Ready, SchedulableRequestState.Executing, SchedulableRequestState.Unscheduled]); 420ErrorUtilities.VerifyThrow(_state != SchedulableRequestState.Ready || result.CircularDependency, "Request can only be Completed from the Ready state if the result indicates a circular dependency occurred."); 430ChangeToState(SchedulableRequestState.Completed); 438VerifyState(SchedulableRequestState.Unscheduled); 441ChangeToState(SchedulableRequestState.Completed); 447public void VerifyState(SchedulableRequestState requiredState) 455public void VerifyOneOfStates(SchedulableRequestState[] requiredStates) 457foreach (SchedulableRequestState requiredState in requiredStates) 473private void ChangeToState(SchedulableRequestState newState) 480SchedulableRequestState previousState = _state; 543if (requestToEvaluate.State == SchedulableRequestState.Unscheduled) 622ChangeToState(SchedulableRequestState.Ready); 628if (requestCausingFailure.State == SchedulableRequestState.Unscheduled) 649if (unblockingRequest.State == SchedulableRequestState.Unscheduled) 656ChangeToState(SchedulableRequestState.Ready);
BackEnd\Components\Scheduler\Scheduler.cs (10)
1361request.VerifyState(SchedulableRequestState.Unscheduled); 1630blockingRequest.VerifyOneOfStates([SchedulableRequestState.Yielding, SchedulableRequestState.Ready, SchedulableRequestState.Blocked]); 2369case SchedulableRequestState.Executing: 2370case SchedulableRequestState.Yielding: 2532String.Format(CultureInfo.InvariantCulture, "{0:0.000}", request.GetTimeSpentInState(SchedulableRequestState.Executing).TotalSeconds), 2533String.Format(CultureInfo.InvariantCulture, "{0:0.000}", request.GetTimeSpentInState(SchedulableRequestState.Executing).TotalSeconds + request.GetTimeSpentInState(SchedulableRequestState.Blocked).TotalSeconds + request.GetTimeSpentInState(SchedulableRequestState.Ready).TotalSeconds),
BackEnd\Components\Scheduler\SchedulingData.cs (26)
303public void UpdateFromState(SchedulableRequest request, SchedulableRequestState previousState) 308case SchedulableRequestState.Blocked: 312case SchedulableRequestState.Yielding: 316case SchedulableRequestState.Completed: 320case SchedulableRequestState.Executing: 325case SchedulableRequestState.Ready: 330case SchedulableRequestState.Unscheduled: 335if (request.State != SchedulableRequestState.Completed) 368case SchedulableRequestState.Blocked: 373case SchedulableRequestState.Yielding: 378case SchedulableRequestState.Completed: 390case SchedulableRequestState.Executing: 397if (previousState == SchedulableRequestState.Unscheduled) 404case SchedulableRequestState.Ready: 418case SchedulableRequestState.Unscheduled: 453ExpectScheduledRequestState(globalRequestId, SchedulableRequestState.Executing); 462ExpectScheduledRequestState(globalRequestId, SchedulableRequestState.Blocked); 485ExpectScheduledRequestState(globalRequestId, SchedulableRequestState.Yielding); 494ExpectScheduledRequestState(globalRequestId, SchedulableRequestState.Ready); 735private void ExpectScheduledRequestState(int globalRequestId, SchedulableRequestState state) 766private SchedulableRequestState _oldState; 771private SchedulableRequestState _newState; 776public SchedulingEvent(DateTime eventTime, SchedulableRequest request, SchedulableRequestState oldState, SchedulableRequestState newState) 803public SchedulableRequestState OldState 811public SchedulableRequestState NewState
BackEnd\Components\Scheduler\SchedulingPlan.cs (1)
468accumulatedTimeByConfiguration[request.BuildRequest.ConfigurationId] = accumulatedTime + request.GetTimeSpentInState(SchedulableRequestState.Executing).TotalMilliseconds;