Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/22/09 00:30:46 (16 years ago)
Author:
svonolfe
Message:

Improved memory consumption, fixed bug that already calculated jobs where reset (#372)

Location:
trunk/sources/HeuristicLab.Hive.Server.Core
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Hive.Server.Core/ClientCommunicator.cs

    r1160 r1166  
    8888            client.State = State.offline;
    8989            clientAdapter.Update(client);
    90             foreach (Job job in jobAdapter.GetJobsOf(client)) {
     90            foreach (Job job in jobAdapter.GetActiveJobsOf(client)) {
    9191              jobManager.ResetJobsDependingOnResults(job);
    9292            }
     
    100100              if (client.State == State.calculating) {
    101101                // check wich job the client was calculating and reset it
    102                 foreach (Job job in jobAdapter.GetJobsOf(client)) {
     102                foreach (Job job in jobAdapter.GetActiveJobsOf(client)) {
    103103                  jobManager.ResetJobsDependingOnResults(job);
    104104                }
     
    195195
    196196      if (hbData.jobProgress != null) {
    197         List<Job> jobsOfClient = new List<Job>(jobAdapter.GetJobsOf(clientAdapter.GetById(hbData.ClientId)));
     197        List<Job> jobsOfClient = new List<Job>(jobAdapter.GetActiveJobsOf(clientAdapter.GetById(hbData.ClientId)));
    198198        if (jobsOfClient == null || jobsOfClient.Count == 0) {
    199199          response.Success = false;
  • trunk/sources/HeuristicLab.Hive.Server.Core/InternalInterfaces/DataAccess/IJobAdapter.cs

    r1000 r1166  
    4848
    4949    /// <summary>
     50    /// Gets all active jobs of the client
     51    /// </summary>
     52    /// <param name="client"></param>
     53    /// <returns></returns>
     54    ICollection<Job> GetActiveJobsOf(ClientInfo client);
     55
     56    /// <summary>
    5057    /// Gets all jobs of the user
    5158    /// </summary>
Note: See TracChangeset for help on using the changeset viewer.