Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
09/07/10 10:22:27 (14 years ago)
Author:
cneumuel
Message:
  • created HiveClient which shows an overview over all submitted HiveExperiments
  • its possible to download all submitted HiveExperiments including results
  • Experiments are now sent as a whole to the Hive and the Hive-Slaves take care of creating child-jobs (if necessary). The parent job is then paused and will be reactivated when all child-jobs are finished
  • WcfService-Clients are now consistently managed by WcfServicePool which allows to use IDisposable-Pattern and always keeps exactly one proxy-object until all callers disposed them.
  • created ProgressView which is able to lock a View and display progress of an action. It also allows to simulate progress if no progress-information is available so that users don't get too nervous while waiting.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.3-Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/Core.cs

    r4337 r4368  
    3030using HeuristicLab.Hive.Slave.Common;
    3131using HeuristicLab.Hive.Slave.Communication;
    32 using HeuristicLab.Hive.Slave.Core.SlaveConsoleService;
     32using HeuristicLab.Hive.Slave.Communication.SlaveFacade;
    3333using HeuristicLab.Hive.Slave.Core.ConfigurationManager;
    3434using HeuristicLab.Hive.Slave.Core.JobStorage;
     35using HeuristicLab.Hive.Slave.Core.SlaveConsoleService;
    3536using HeuristicLab.Hive.Slave.ExecutionEngine;
    3637using HeuristicLab.Tracing;
    37 using HeuristicLab.Hive.Slave.Communication.SlaveService;
    3838
    3939namespace HeuristicLab.Hive.Slave.Core {
     
    205205          WcfService.Instance.Logout(ConfigManager.Instance.GetClientInfo().Id);
    206206          break;
    207       }
     207
     208        case MessageContainer.MessageType.AddChildJob:
     209          AddChildJob((MessageContainerWithJob)container);
     210          break;
     211
     212        case MessageContainer.MessageType.PauseJob:
     213          // send the job back to hive
     214          PauseJob((MessageContainerWithJob)container);
     215          break;
     216
     217        case MessageContainer.MessageType.GetChildJobs:
     218          // send the job back to hive
     219          GetChildJobs((MessageContainerWithCallback<SerializedJobList>)container);
     220          break;
     221      }
     222    }
     223
     224    private void GetChildJobs(MessageContainerWithCallback<SerializedJobList> mc) {
     225      ResponseObject<SerializedJobList> response = wcfService.GetChildJobs(mc.JobId);
     226      if (response.StatusMessage != ResponseStatus.Ok) {
     227        Logger.Error("GetChildJobs failed: " + response.StatusMessage);
     228      } else {
     229        mc.Callback(response.Obj);
     230      }
     231    }
     232
     233    private void PauseJob(MessageContainerWithJob mc) {
     234      ResponseObject<JobDto> response = wcfService.PauseJob(mc.SerializedJob);
     235      KillAppDomain(mc.JobId);
     236      if (response.StatusMessage != ResponseStatus.Ok) {
     237        Logger.Error("PauseJob failed: " + response.StatusMessage);
     238      }
     239    }
     240
     241    private ResponseObject<JobDto> AddChildJob(MessageContainerWithJob mc) {
     242      ResponseObject<JobDto> response = wcfService.AddChildJob(mc.JobId, mc.SerializedJob);
     243      if (response.StatusMessage != ResponseStatus.Ok) {
     244        Logger.Error("AddChildJob failed: " + response.StatusMessage);
     245      }
     246      return response;
    208247    }
    209248
     
    462501            appDomains.Remove(id);
    463502          }
     503
    464504          engines.Remove(id);
    465505          jobs.Remove(id);
Note: See TracChangeset for help on using the changeset viewer.