- Timestamp:
- 11/27/12 19:57:06 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SlaveShutdown/HeuristicLab.Clients.Hive.Slave/3.3/Core.cs
r8949 r8953 25 25 using System.Threading; 26 26 using System.Threading.Tasks; 27 using HeuristicLab.Clients.Hive.SlaveCore.Properties;28 27 using HeuristicLab.Common; 29 28 using HeuristicLab.Core; … … 53 52 54 53 public Core() { 55 var log = new ThreadSafeLog(S ettings.Default.MaxLogCount);54 var log = new ThreadSafeLog(SlaveCore.Properties.Settings.Default.MaxLogCount); 56 55 this.pluginManager = new PluginManager(WcfService.Instance, log); 57 56 this.taskManager = new TaskManager(pluginManager, log); … … 454 453 455 454 private void ShutdownComputer() { 456 Shutdown(); 457 458 try { 459 Process.Start(Settings.Default.ShutdownCommand); 460 } 461 catch (Exception ex) { 462 if (ServiceEventLog != null) { 463 EventLogManager.LogException(ex); 464 } else 465 throw ex; 466 } 455 var t = TS.Task.Factory.StartNew(new Action(Shutdown)); 456 t.ContinueWith(c => { 457 try { 458 Process.Start(SlaveCore.Properties.Settings.Default.ShutdownCommand); 459 } 460 catch (Exception ex) { 461 if (ServiceEventLog != null) { 462 EventLogManager.LogException(ex); 463 } else 464 throw ex; 465 } 466 }); 467 467 } 468 468
Note: See TracChangeset
for help on using the changeset viewer.