- Timestamp:
- 07/18/14 12:01:13 (10 years ago)
- Location:
- branches/HiveStatistics/sources
- Files:
-
- 57 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HiveStatistics/sources
- Property svn:ignore
-
old new 8 8 FxCopResults.txt 9 9 Google.ProtocolBuffers-0.9.1.dll 10 Google.ProtocolBuffers-2.4.1.473.dll 10 11 HeuristicLab 3.3.5.1.ReSharper.user 11 12 HeuristicLab 3.3.6.0.ReSharper.user 12 13 HeuristicLab.4.5.resharper.user 13 14 HeuristicLab.ExtLibs.6.0.ReSharper.user 15 HeuristicLab.Scripting.Development 14 16 HeuristicLab.resharper.user 15 17 ProtoGen.exe … … 17 19 _ReSharper.HeuristicLab 18 20 _ReSharper.HeuristicLab 3.3 21 _ReSharper.HeuristicLab 3.3 Tests 19 22 _ReSharper.HeuristicLab.ExtLibs 20 23 bin 21 24 protoc.exe 22 _ReSharper.HeuristicLab 3.3 Tests23 Google.ProtocolBuffers-2.4.1.473.dll
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ConcurrentTaskDownloader.cs
r9219 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 46 46 47 47 task.ContinueWith((x) => OnTaskFinished(x, onFinishedAction), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnRanToCompletion); 48 task.ContinueWith((x) => OnTaskFailed(x , onFinishedAction), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnFaulted);48 task.ContinueWith((x) => OnTaskFailed(x), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnFaulted); 49 49 } 50 50 … … 55 55 56 56 task.ContinueWith((x) => OnTaskFinished(x, onFinishedAction), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnRanToCompletion); 57 task.ContinueWith((x) => OnTaskFailed(x , onFinishedAction), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnFaulted);57 task.ContinueWith((x) => OnTaskFailed(x), TaskContinuationOptions.ExecuteSynchronously | TaskContinuationOptions.OnlyOnFaulted); 58 58 } 59 59 … … 61 61 onFinishedAction(task.Result.Item1, task.Result.Item2); 62 62 } 63 private void OnTaskFailed(Task<Tuple<Task, T>> task , Action<Task, T> onFinishedAction) {63 private void OnTaskFailed(Task<Tuple<Task, T>> task) { 64 64 task.Exception.Flatten().Handle((e) => { return true; }); 65 65 OnExceptionOccured(task.Exception.Flatten()); 66 onFinishedAction(task.Result.Item1, null);67 66 } 68 67 -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ConcurrentTaskDownloaderException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/AddTaskToHiveException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/AnonymousUserException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/HiveException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/OptimizerNotFoundException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/ResourceNotFoundException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/ServiceClientFactoryException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Exceptions/TaskResultPollingException.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveAdminClient.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveClient.cs
r9646 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 265 265 try { 266 266 refreshableJob.IsProgressing = true; 267 refreshableJob.Progress = new Progress("Connecting to server...");267 refreshableJob.Progress.Start("Connecting to server..."); 268 268 IEnumerable<string> resourceNames = ToResourceNameList(refreshableJob.Job.ResourceNames); 269 269 var resourceIds = new List<Guid>(); … … 351 351 /// </summary> 352 352 /// <param name="parentHiveTask">shall be null if its the root task</param> 353 private void UploadTaskWithChildren( Progress progress, HiveTask hiveTask, HiveTask parentHiveTask, IEnumerable<Guid> groups, int[] taskCount, int totalJobCount, Guid configPluginId, Guid jobId, ILog log, bool isPrivileged, CancellationToken cancellationToken) {353 private void UploadTaskWithChildren(IProgress progress, HiveTask hiveTask, HiveTask parentHiveTask, IEnumerable<Guid> groups, int[] taskCount, int totalJobCount, Guid configPluginId, Guid jobId, ILog log, bool isPrivileged, CancellationToken cancellationToken) { 354 354 taskUploadSemaphore.WaitOne(); 355 355 bool semaphoreReleased = false; … … 362 362 List<IPluginDescription> plugins; 363 363 364 if (hiveTask.ItemTask.ComputeInParallel && (hiveTask.ItemTask.Item is Optimization.Experiment || hiveTask.ItemTask.Item is Optimization.BatchRun)) {364 if (hiveTask.ItemTask.ComputeInParallel) { 365 365 hiveTask.Task.IsParentTask = true; 366 366 hiveTask.Task.FinishWhenChildJobsFinished = true; … … 424 424 var hiveExperiment = refreshableJob.Job; 425 425 refreshableJob.IsProgressing = true; 426 refreshableJob.Progress = new Progress();427 426 TaskDownloader downloader = null; 428 427 … … 431 430 IEnumerable<LightweightTask> allTasks; 432 431 433 refreshableJob.Progress.Status = "Connecting to Server...";434 432 // fetch all task objects to create the full tree of tree of HiveTask objects 435 refreshableJob.Progress.Sta tus = "Downloading list of tasks...";433 refreshableJob.Progress.Start("Downloading list of tasks..."); 436 434 allTasks = HiveServiceLocator.Instance.CallHiveService(s => s.GetLightweightJobTasksWithoutStateLog(hiveExperiment.Id)); 437 435 totalJobCount = allTasks.Count(); -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveServiceLocator.cs
r9461 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 21 21 22 22 using System; 23 using System.ServiceModel; 23 24 using HeuristicLab.Clients.Common; 24 25 … … 35 36 } 36 37 38 private HiveServiceLocator() { 39 } 40 37 41 private string username; 38 42 public string Username { … … 47 51 } 48 52 49 p rivate int endpointRetries;53 public int EndpointRetries { get; private set; } 50 54 51 p rivate string workingEndpoint;55 public string WorkingEndpoint { get; private set; } 52 56 53 57 private HiveServiceClient NewServiceClient() { 54 if ( endpointRetries >= Settings.Default.MaxEndpointRetries) {55 return CreateClient( workingEndpoint);58 if (EndpointRetries >= Settings.Default.MaxEndpointRetries) { 59 return CreateClient(WorkingEndpoint); 56 60 } 57 61 … … 63 67 var cl = CreateClient(endpointConfigurationName); 64 68 cl.Open(); 65 workingEndpoint = endpointConfigurationName;69 WorkingEndpoint = endpointConfigurationName; 66 70 return cl; 67 71 } 68 catch (E xception exc) {72 catch (EndpointNotFoundException exc) { 69 73 exception = exc; 70 endpointRetries++;74 EndpointRetries++; 71 75 } 72 76 } 73 77 74 throw exception ;78 throw exception ?? new Exception("No endpoint for Hive service found."); 75 79 } 76 80 -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveTasks/EngineHiveTask.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 32 32 #region Constructors and cloning 33 33 public EngineHiveTask() { } 34 public EngineHiveTask(EngineTask engine Job, IScope parentScopeClone)35 : base(engine Job) {34 public EngineHiveTask(EngineTask engineTask, IScope parentScopeClone) 35 : base(engineTask) { 36 36 this.parentScopeClone = parentScopeClone; 37 37 } -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveTasks/HiveTask.cs
r9251 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 172 172 protected HiveTask(bool deserializing) { } 173 173 174 public HiveTask() { 174 public HiveTask() 175 : base() { 176 Name = "Hive Task"; 175 177 this.Task = new Task() { CoresNeeded = 1, MemoryNeeded = 128 }; 176 178 task.State = TaskState.Offline; … … 180 182 } 181 183 182 public HiveTask(ItemTask item Job, bool autoCreateChildHiveJobs)184 public HiveTask(ItemTask itemTask, bool autoCreateChildHiveTasks) 183 185 : this() { 184 this.syncTasksWithOptimizers = autoCreateChildHive Jobs;185 this.ItemTask = item Job;186 this.syncTasksWithOptimizers = autoCreateChildHiveTasks; 187 this.ItemTask = itemTask; 186 188 this.syncTasksWithOptimizers = true; 187 189 } 188 190 189 public HiveTask(Task job, TaskData taskData, bool autoCreateChildHiveTasks) {191 public HiveTask(Task task, TaskData taskData, bool autoCreateChildHiveTasks) { 190 192 this.syncTasksWithOptimizers = autoCreateChildHiveTasks; 191 this.Task = job;193 this.Task = task; 192 194 try { 193 195 this.ItemTask = PersistenceUtil.Deserialize<ItemTask>(taskData.Data); … … 543 545 public new T ItemTask { 544 546 get { return (T)base.ItemTask; } 545 internalset { base.ItemTask = value; }547 set { base.ItemTask = value; } 546 548 } 547 549 … … 550 552 [StorableConstructor] 551 553 protected HiveTask(bool deserializing) { } 552 public HiveTask(T item Job) : base(itemJob, true) { }554 public HiveTask(T itemTask) : base(itemTask, true) { } 553 555 protected HiveTask(HiveTask<T> original, Cloner cloner) 554 556 : base(original, cloner) { -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/HiveTasks/OptimizerHiveTask.cs
r9219 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 26 26 using HeuristicLab.Collections; 27 27 using HeuristicLab.Common; 28 using HeuristicLab.MainForm; 28 29 using HeuristicLab.Optimization; 29 30 using HeuristicLab.PluginInfrastructure; … … 31 32 namespace HeuristicLab.Clients.Hive { 32 33 public class OptimizerHiveTask : HiveTask<OptimizerTask> { 34 public Progress Progress { get; private set; } 35 33 36 #region Constructors and Cloning 34 public OptimizerHiveTask() { } 37 public OptimizerHiveTask() { 38 Progress = new Progress(); 39 } 35 40 public OptimizerHiveTask(IOptimizer optimizer) 36 41 : this() { … … 43 48 protected OptimizerHiveTask(OptimizerHiveTask original, Cloner cloner) 44 49 : base(original, cloner) { 50 Progress = new Progress(); 45 51 } 46 52 public override IDeepCloneable Clone(Cloner cloner) { -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/IHiveServiceLocator.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/JobResultPoller.cs
r9097 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Plugin.cs.frame
r8246 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 27 27 28 28 namespace HeuristicLab.Clients.Hive { 29 [Plugin("HeuristicLab.Clients.Hive", "3.3. 7.$WCREV$")]29 [Plugin("HeuristicLab.Clients.Hive", "3.3.10.$WCREV$")] 30 30 [PluginFile("HeuristicLab.Clients.Hive-3.3.dll", PluginFileType.Assembly)] 31 31 [PluginDependency("HeuristicLab.Clients.Common", "3.3")] -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Properties/AssemblyInfo.cs.frame
r8246 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 32 32 [assembly: AssemblyCompany("")] 33 33 [assembly: AssemblyProduct("HeuristicLab")] 34 [assembly: AssemblyCopyright("(c) 2002-201 2HEAL")]34 [assembly: AssemblyCopyright("(c) 2002-2014 HEAL")] 35 35 [assembly: AssemblyTrademark("")] 36 36 [assembly: AssemblyCulture("")] … … 55 55 // [assembly: AssemblyVersion("1.0.*")] 56 56 [assembly: AssemblyVersion("3.3.0.0")] 57 [assembly: AssemblyFileVersion("3.3. 7.$WCREV$")]57 [assembly: AssemblyFileVersion("3.3.10.$WCREV$")] -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/RefreshableJob.cs
r9444 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 157 157 } 158 158 159 private Progress progress;160 public Progress Progress {159 private IProgress progress; 160 public IProgress Progress { 161 161 get { return progress; } 162 162 set { … … 178 178 #region Constructors and Cloning 179 179 public RefreshableJob() { 180 this.progress = new Progress(); 180 181 this.refreshAutomatically = false; 181 182 this.Job = new Job(); … … 186 187 } 187 188 public RefreshableJob(Job hiveJob) { 189 this.progress = new Progress(); 188 190 this.refreshAutomatically = true; 189 191 this.Job = hiveJob; -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ScopeExtensions.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Downtime.cs
r8957 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Heartbeat.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/HiveItem.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/HiveItemCollection.cs
r9219 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/IHiveItem.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Job.cs
r9107 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/JobPermission.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/LightweightTask.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/MessageContainer.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/NamedHiveItem.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Plugin.cs
r7532 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/PluginData.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Resource.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/ResourcePermission.cs
r7916 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Slave.cs
r7857 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/SlaveGroup.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/SlaveStatistics.cs
r9221 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/StateLog.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Statistics.cs
r9221 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/Task.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 27 27 public partial class Task : LightweightTask { 28 28 29 public Task() { } 29 public Task() { 30 Priority = 1; 31 } 30 32 31 33 protected Task(Task original, Cloner cloner) -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/TaskData.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/UserPriority.cs
r9221 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/ServiceClients/UserStatistics.cs
r9221 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Settings.Designer.cs
r9461 r11202 2 2 // <auto-generated> 3 3 // This code was generated by a tool. 4 // Runtime Version:4.0.30319.180 344 // Runtime Version:4.0.30319.18047 5 5 // 6 6 // Changes to this file may cause incorrect behavior and will be lost if … … 26 26 [global::System.Configuration.ApplicationScopedSettingAttribute()] 27 27 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 28 [global::System.Configuration.DefaultSettingValueAttribute(" 16")]28 [global::System.Configuration.DefaultSettingValueAttribute("2")] 29 29 public int MaxParallelUploads { 30 30 get { … … 93 93 [global::System.Configuration.ApplicationScopedSettingAttribute()] 94 94 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 95 [global::System.Configuration.DefaultSettingValueAttribute(" 5")]95 [global::System.Configuration.DefaultSettingValueAttribute("3")] 96 96 public int MaxEndpointRetries { 97 97 get { -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Settings.settings
r9461 r11202 4 4 <Settings> 5 5 <Setting Name="MaxParallelUploads" Type="System.Int32" Scope="Application"> 6 <Value Profile="(Default)"> 16</Value>6 <Value Profile="(Default)">2</Value> 7 7 </Setting> 8 8 <Setting Name="HLBinaryName" Type="System.String" Scope="Application"> … … 29 29 </Setting> 30 30 <Setting Name="MaxEndpointRetries" Type="System.Int32" Scope="Application"> 31 <Value Profile="(Default)"> 5</Value>31 <Value Profile="(Default)">3</Value> 32 32 </Setting> 33 33 </Settings> -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/StateLogList.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/StateLogListList.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/TaskDownloader.cs
r9219 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 24 24 using System.Linq; 25 25 using System.Threading; 26 using HeuristicLab.Clients.Hive.Jobs;27 26 using HeuristicLab.Common; 28 27 … … 79 78 80 79 public TaskDownloader(IEnumerable<Guid> jobIds) { 81 t his.taskIds = jobIds;82 t his.taskDownloader = new ConcurrentTaskDownloader<ItemTask>(Settings.Default.MaxParallelDownloads, Settings.Default.MaxParallelDownloads);83 t his.taskDownloader.ExceptionOccured += new EventHandler<EventArgs<Exception>>(taskDownloader_ExceptionOccured);84 this.results = new Dictionary<Guid, HiveTask>();80 taskIds = jobIds; 81 taskDownloader = new ConcurrentTaskDownloader<ItemTask>(Settings.Default.MaxParallelDownloads, Settings.Default.MaxParallelDownloads); 82 taskDownloader.ExceptionOccured += new EventHandler<EventArgs<Exception>>(taskDownloader_ExceptionOccured); 83 results = new Dictionary<Guid, HiveTask>(); 85 84 } 86 85 … … 88 87 foreach (Guid taskId in taskIds) { 89 88 taskDownloader.DownloadTaskDataAndTask(taskId, 90 (localJob, itemJob) => { 91 if (localJob != null && itemJob != null) { 92 HiveTask hiveTask; 93 if (itemJob is OptimizerTask) { 94 hiveTask = new OptimizerHiveTask((OptimizerTask)itemJob); 95 } else { 96 hiveTask = new HiveTask(itemJob, true); 97 } 98 hiveTask.Task = localJob; 89 (localTask, itemTask) => { 90 if (localTask != null && itemTask != null) { 91 HiveTask hiveTask = itemTask.CreateHiveTask(); 92 hiveTask.Task = localTask; 99 93 try { 100 94 resultsLock.EnterWriteLock(); 101 this.results.Add(localJob.Id, hiveTask);95 results.Add(localTask.Id, hiveTask); 102 96 } 103 97 finally { resultsLock.ExitWriteLock(); } … … 113 107 public event EventHandler<EventArgs<Exception>> ExceptionOccured; 114 108 private void OnExceptionOccured(Exception exception) { 115 this.exceptionOccured = true;116 this.currentException = exception;109 exceptionOccured = true; 110 currentException = exception; 117 111 var handler = ExceptionOccured; 118 112 if (handler != null) handler(this, new EventArgs<Exception>(exception)); -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Tasks/EngineTask.cs
r7532 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 29 29 [StorableClass] 30 30 public class EngineTask : ItemTask { 31 public override HiveTask CreateHiveTask() { 32 //only used when deserializing, so no problem with parentscope 33 return new EngineHiveTask(this, null); 34 } 35 31 36 [Storable] 32 37 protected IOperation initialOperation; … … 50 55 51 56 #region constructors and cloning 52 public EngineTask() { }53 57 public EngineTask(IOperation initialOperation, IEngine engine) { 54 58 this.initialOperation = initialOperation; 55 59 this.Item = engine; 56 60 } 61 62 public EngineTask(IEngine engine) : base(engine) { } 57 63 58 64 [StorableConstructor] … … 144 150 145 151 public override string Name { 146 get { return Item != null ? Item.ToString() : null; }152 get { return Item != null ? Item.ToString() : "Engine Task"; } 147 153 set { throw new NotSupportedException(); } 148 154 } … … 153 159 154 160 public override string ItemName { 155 get { return "Engine Task"; }161 get { return "Engine Task"; } 156 162 } 157 163 } -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Tasks/ItemTask.cs
r7532 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 22 22 using System; 23 23 using System.Drawing; 24 using System.Linq; 24 25 using HeuristicLab.Common; 25 26 using HeuristicLab.Core; 26 27 using HeuristicLab.Hive; 27 28 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 using HeuristicLab.PluginInfrastructure; 28 30 29 31 namespace HeuristicLab.Clients.Hive { … … 31 33 [StorableClass] 32 34 public abstract class ItemTask : NamedItem, ITask { 35 public virtual HiveTask CreateHiveTask() { 36 return new HiveTask(this, true); 37 } 38 33 39 public virtual bool IsParallelizable { 34 40 get { return true; } 41 set { } 35 42 } 36 43 … … 71 78 this.Item = cloner.Clone(original.Item); 72 79 } 80 public ItemTask(IItem item) { 81 Item = item; 82 } 73 83 74 84 [StorableHook(HookType.AfterDeserialization)] … … 211 221 return Name; 212 222 } 223 224 #region Helpers 225 public static bool IsTypeSupported(Type itemType) { 226 var supportedHiveTaskTypes = ApplicationManager.Manager.GetTypes(typeof(ItemTask)) 227 .Select(t => t.GetProperties().Single(x => x.Name == "Item" && x.PropertyType != typeof(IItem)).PropertyType); 228 return supportedHiveTaskTypes.Any(x => x.IsAssignableFrom(itemType)); 229 } 230 231 public static Type GetHiveTaskType(Type itemType) { 232 if (!IsTypeSupported(itemType)) throw new Exception("Item " + itemType + " is not supported for Hive."); 233 234 var typeHiveTaskMap = ApplicationManager.Manager.GetTypes(typeof(ItemTask)) 235 .Select(t => new Tuple<Type, Type>(t.GetProperties().Single(x => x.Name == "Item" && x.PropertyType != typeof(IItem)).PropertyType, t)); 236 237 return typeHiveTaskMap.Single(x => x.Item1.IsAssignableFrom(itemType)).Item2; 238 } 239 240 public static ItemTask GetItemTaskForItem(IItem item) { 241 Type itemType = item.GetType(); 242 Type hiveTaskType = GetHiveTaskType(itemType); 243 return Activator.CreateInstance(hiveTaskType, new object[] { item }) as ItemTask; 244 } 245 #endregion 213 246 } 214 247 } -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Tasks/OptimizerTask.cs
r7530 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 30 30 [StorableClass] 31 31 public class OptimizerTask : ItemTask { 32 public override HiveTask CreateHiveTask() { 33 return new OptimizerHiveTask(this); 34 } 35 32 36 public override bool IsParallelizable { 33 37 get { return this.Item is Experiment || this.Item is BatchRun; } … … 46 50 } 47 51 48 public OptimizerTask() : base() { }49 52 public OptimizerTask(IOptimizer optimizer) 50 : this() { 51 this.Item = optimizer; 52 53 if (optimizer is Experiment) { 53 : base(optimizer) { 54 55 if (optimizer is Experiment || optimizer is BatchRun) { 54 56 this.ComputeInParallel = true; 55 } else if (optimizer is BatchRun) {56 this.ComputeInParallel = false;57 57 } else { 58 58 this.ComputeInParallel = false; … … 210 210 get { 211 211 if (Item == null) 212 return string.Empty;212 return "Optimizer Task"; 213 213 else 214 214 return Item.Name; -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/TreeView/IItemTree.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/TreeView/IItemTreeAction.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Util/PersistenceUtil.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HiveStatistics/sources/HeuristicLab.Clients.Hive/3.3/Util/PluginUtil.cs
r7259 r11202 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab.
Note: See TracChangeset
for help on using the changeset viewer.