Changeset 6897
- Timestamp:
- 10/10/11 15:20:01 (13 years ago)
- Location:
- branches/HeuristicLab.Hive-3.4/sources
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Clients.Hive.Administrator/3.3/Views/ResourcesView.cs
r6893 r6897 196 196 void SlaveViewContent_PropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e) { 197 197 OnContentChanged(); 198 if (e.PropertyName == "HbInterval") { 199 UpdateChildHbIntervall(slaveView.Content); 200 } 201 } 202 203 private void UpdateChildHbIntervall(Resource resource) { 204 foreach (Resource r in Content.Where(x => x.ParentResourceId == resource.Id)) { 205 r.HbInterval = resource.HbInterval; 206 if (r is SlaveGroup) { 207 UpdateChildHbIntervall(r); 208 } 209 } 198 210 } 199 211 -
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Clients.Hive.Administrator/3.3/Views/SlaveView.cs
r6893 r6897 124 124 Content.HbInterval = interval; 125 125 } 126 catch (Exception ex) {126 catch (Exception) { 127 127 MessageBox.Show("Please enter a numeric value for the Heartbeat Interval.", "HeuristicLab Hive Administrator", MessageBoxButtons.OK, MessageBoxIcon.Error); 128 txtHbIntervall.Text = " 0";128 txtHbIntervall.Text = "10"; 129 129 } 130 130 } -
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Clients.Hive.Slave.WindowsService/3.3/SlaveWindowsService.cs
r6744 r6897 33 33 try { 34 34 if (!System.Diagnostics.EventLog.SourceExists("HLHive")) { 35 System.Diagnostics.EventLog.CreateEventSource("HLHive", " Slave");35 System.Diagnostics.EventLog.CreateEventSource("HLHive", "HiveSlave"); 36 36 } 37 37 eventLog.Source = "HLHive"; 38 eventLog.Log = " Slave";38 eventLog.Log = "HiveSlave"; 39 39 } 40 40 catch (Exception) { } -
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Clients.Hive.Slave/3.3/Manager/ConfigManager.cs
r6725 r6897 25 25 using System.Linq; 26 26 using System.Management; 27 using HeuristicLab.Clients.Hive.SlaveCore.Properties; 27 28 28 29 … … 51 52 public ConfigManager(TaskManager jobManager) { 52 53 this.jobManager = jobManager; 54 UpdateSlaveInfo(); 55 } 56 57 private void UpdateSlaveInfo() { 53 58 cpuCounter = new PerformanceCounter(); 54 59 cpuCounter.CategoryName = "Processor"; … … 66 71 slave.CpuSpeed = GetCpuSpeed(); 67 72 slave.FreeMemory = GetFreeMemory(); 73 slave.HbInterval = (int)Settings.Default.HeartbeatInterval.TotalSeconds; 68 74 } 69 75 … … 73 79 /// <returns>the ClientInfo object</returns> 74 80 public Slave GetClientInfo() { 81 UpdateSlaveInfo(); 75 82 return slave; 76 83 } -
branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Services.Hive/3.3/HiveService.cs
r6893 r6897 496 496 authen.AuthenticateForAnyRole(HiveRoles.Administrator); 497 497 trans.UseTransaction(() => { 498 UpdateSlaveHBs(slaveGroup); 499 }); 500 } 501 502 private void UpdateSlaveHBs(Resource r) { 503 foreach (Resource resource in dao.GetChildResources(r.Id)) { 504 if (resource is SlaveGroup) { 505 resource.HbInterval = r.HbInterval; 506 dao.UpdateSlaveGroup(resource as SlaveGroup); 507 UpdateSlaveHBs(resource); 508 } else if (resource is Slave) { 509 resource.HbInterval = r.HbInterval; 510 dao.UpdateSlave(resource as Slave); 511 } 512 } 498 dao.UpdateSlaveGroup(slaveGroup); 499 }); 513 500 } 514 501
Note: See TracChangeset
for help on using the changeset viewer.