Changeset 4116 for branches/3.3-HiveMigration/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/DefaultScheduler.cs
- Timestamp:
- 07/27/10 18:36:36 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.3-HiveMigration/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/DefaultScheduler.cs
r4060 r4116 26 26 public bool ExistsJobForClient(HeuristicLab.Hive.Contracts.BusinessObjects.HeartBeatData hbData) { 27 27 List<JobDto> allOfflineJobsForClient = 28 new List<JobDto>(DaoLocator.JobDao.FindFittingJobsForClient(State. offline, hbData.FreeCores, hbData.FreeMemory,28 new List<JobDto>(DaoLocator.JobDao.FindFittingJobsForClient(State.Offline, hbData.FreeCores, hbData.FreeMemory, 29 29 hbData.ClientId)); 30 30 return (allOfflineJobsForClient != null && allOfflineJobsForClient.Count > 0); … … 38 38 ClientDto client = DaoLocator.ClientDao.FindById(clientId); 39 39 LinkedList<JobDto> allOfflineJobsForClient = 40 new LinkedList<JobDto>(DaoLocator.JobDao.FindFittingJobsForClient(State. offline, client.NrOfFreeCores,40 new LinkedList<JobDto>(DaoLocator.JobDao.FindFittingJobsForClient(State.Offline, client.NrOfFreeCores, 41 41 client.FreeMemory, client.Id)); 42 42 if (allOfflineJobsForClient != null && allOfflineJobsForClient.Count > 0) { 43 43 jobToCalculate = allOfflineJobsForClient.First.Value; 44 jobToCalculate.State = State. calculating;44 jobToCalculate.State = State.Calculating; 45 45 jobToCalculate.Client = client; 46 jobToCalculate.Client.State = State. calculating;46 jobToCalculate.Client.State = State.Calculating; 47 47 jobToCalculate.DateCalculated = DateTime.Now; 48 48 DaoLocator.JobDao.AssignClientToJob(client.Id, jobToCalculate.Id);
Note: See TracChangeset
for help on using the changeset viewer.