Changeset 1595


Ignore:
Timestamp:
04/17/09 13:40:40 (12 years ago)
Author:
aleitner
Message:

bugfix on showing a client if changes on status and capacity (#585)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Hive.Server.Console/3.2/HiveServerManagementConsole.cs

    r1590 r1595  
    371371            State state = clientInfo.List[change.Position].State;
    372372            System.Diagnostics.Debug.WriteLine(lvClientControl.Items[i].Text.ToString());
    373             int percentageUsage = CapacityRam(currentClient.NrOfCores, currentClient.NrOfFreeCores);
     373
     374            ClientInfo ci = null;
     375
     376            foreach (ClientInfo c in clientInfo.List) {
     377              if (c.Id == change.ID) {
     378                ci = c;
     379              }
     380            }
     381
     382            int percentageUsage = CapacityRam(ci.NrOfCores, ci.NrOfFreeCores);
    374383            if ((state == State.offline) || (state == State.nullState)) {
    375384              lvClientControl.Items[i].ImageIndex = 3;
     
    553562          if (ci.Id.Equals(cio.Id)) {
    554563            found = true;
    555             if ((ci.State != cio.State) || (ci.NrOfFreeCores != ci.NrOfFreeCores)) {
     564            if ((ci.State != cio.State) || (ci.NrOfFreeCores != cio.NrOfFreeCores)) {
    556565              changes.Add(new Changes { Types = Type.Client, ID = ci.Id, ChangeType = Change.Update, Position = i });
    557566            }
Note: See TracChangeset for help on using the changeset viewer.