Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
02/03/13 16:17:44 (11 years ago)
Author:
ascheibe
Message:

#2005

  • add repeating of failed tasks and task datas
  • added an additional ws method that loads lightweight tasks without the statelogs
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UnloadJobs/HeuristicLab.Clients.Hive/3.3/ConcurrentTaskDownloader.cs

    r9170 r9202  
    6868
    6969    private Task DownloadTask(object taskId) {
    70       return HiveServiceLocator.Instance.CallHiveService(s => s.GetTask((Guid)taskId));
     70      Task t = null;
     71      HiveClient.TryAndRepeat(() => {
     72        t = HiveServiceLocator.Instance.CallHiveService(s => s.GetTask((Guid)taskId));
     73      }, Settings.Default.MaxRepeatServiceCalls, "Failed to download task.");
     74      return t;
    7175    }
    7276
     
    7781    protected Tuple<Task, TaskData> DownloadTaskData(Task task) {
    7882      downloadSemaphore.WaitOne();
    79       TaskData result;
     83      TaskData result = null;
    8084      try {
    8185        if (abort) return null;
    82         result = HiveServiceLocator.Instance.CallHiveService(s => s.GetTaskData(task.Id));
     86        HiveClient.TryAndRepeat(() => {
     87          result = HiveServiceLocator.Instance.CallHiveService(s => s.GetTaskData(task.Id));
     88        }, Settings.Default.MaxRepeatServiceCalls, "Failed to download task data.");
    8389      }
    8490      finally {
Note: See TracChangeset for help on using the changeset viewer.