Changeset 6717 for branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Services.Hive/3.3/Manager/HeartbeatManager.cs
- Timestamp:
- 09/08/11 10:38:36 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Services.Hive/3.3/Manager/HeartbeatManager.cs
r6463 r6717 23 23 using System.Collections.Generic; 24 24 using System.Linq; 25 using HeuristicLab.Services.Hive. Common;26 using HeuristicLab.Services.Hive.Common.DataTransfer;25 using HeuristicLab.Services.Hive.DataTransfer; 26 using DA = HeuristicLab.Services.Hive.DataAccess; 27 27 28 28 namespace HeuristicLab.Services.Hive { 29 29 public class HeartbeatManager { 30 private DataAccess.IHiveDao dao {30 private IHiveDao dao { 31 31 get { return ServiceLocator.Instance.HiveDao; } 32 32 } … … 75 75 if (dao.GetJob(job.Id).State != JobState.Waiting) return false; 76 76 77 job = dao.UpdateJobState(job.Id, JobState.Transferring, slave.Id, null, null);77 job = dao.UpdateJobState(job.Id, DataAccess.JobState.Transferring, slave.Id, null, null); 78 78 79 79 // from now on the job has some time to send the next heartbeat (ApplicationConstants.TransferringJobHeartbeatTimeout) … … 102 102 // job does not exist in db 103 103 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, jobProgress.Key)); 104 LogFactory.GetLogger(this.GetType().Namespace).Log("Job does not exist in DB: " + jobProgress.Key);104 DA.LogFactory.GetLogger(this.GetType().Namespace).Log("Job does not exist in DB: " + jobProgress.Key); 105 105 } else { 106 106 if (curJob.CurrentStateLog.SlaveId == Guid.Empty || curJob.CurrentStateLog.SlaveId != heartbeat.SlaveId) { 107 107 // assigned slave does not match heartbeat 108 108 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, curJob.Id)); 109 LogFactory.GetLogger(this.GetType().Namespace).Log("The slave " + heartbeat.SlaveId + " is not supposed to calculate Job: " + curJob);109 DA.LogFactory.GetLogger(this.GetType().Namespace).Log("The slave " + heartbeat.SlaveId + " is not supposed to calculate Job: " + curJob); 110 110 } else if (!JobIsAllowedToBeCalculatedBySlave(heartbeat.SlaveId, curJob)) { 111 111 // assigned resources ids of job do not match with slaveId (and parent resourceGroupIds); this might happen when slave is moved to different group
Note: See TracChangeset
for help on using the changeset viewer.