Skip to content
Snippets Groups Projects
  1. Jan 16, 2013
  2. Jan 15, 2013
  3. Jan 14, 2013
  4. Jan 10, 2013
  5. Jan 08, 2013
  6. Jan 07, 2013
  7. Jan 04, 2013
  8. Dec 28, 2012
    • Iustin Pop's avatar
      Fix a bad data type in Hcheck.hs · f6b9c6e5
      Iustin Pop authored
      
      While trying to understand why some code was not being tested, I
      realised that we have a bad data type in Hcheck.hs.
      
      We have "data Level = GroupLvl | ClusterLvl", but then we need to pass
      the group name/index as well, so we have functions that look like the
      following:
      
        f :: Level -> Maybe String -> …
        f GroupLvl (Just gname) = …
        f GroupLvl Nothing = … -- never used
        f ClusterLvl _ = … -- wrong, since a (Just x) could be passed
      
      It's clear that we just need to move the group name in the "GroupLvl"
      constructor, and simplify the call chain.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      f6b9c6e5
    • Iustin Pop's avatar
      Move src/Ganeti/HTools/Program.hs to Program/Main.hs · 2fd5a116
      Iustin Pop authored
      
      This removes one more tab conflict; this is the last module in our
      code where we have both x.hs and x/.
      
      Furthermore, we collapse all actual code into the new Main.hs module,
      leaving the htools.hs basically empty (will allow better testing in
      the future).
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      2fd5a116
  9. Dec 24, 2012
  10. Mar 20, 2009
  11. Mar 14, 2009
  12. Mar 13, 2009
    • Iustin Pop's avatar
      Some more docstring updates · 00b51a14
      Iustin Pop authored
      00b51a14
    • Iustin Pop's avatar
      Enhance the command list for the solution · 142538ff
      Iustin Pop authored
      This patch moves the formatting of the command list to Cluster.hs and
      enhances it with separator messages between the steps.
      142538ff
    • Iustin Pop's avatar
      Add a new ReplaceAndFailover move · 79ac6b6f
      Iustin Pop authored
      This patch adds a new replace secondary and failover move (equals to
      “r:x f”), which can improve the solution (since we are testing more
      options at each step).
      79ac6b6f
    • Iustin Pop's avatar
      Some whitespace changes · fd934a28
      Iustin Pop authored
      Aligned the comments in Instance.hs
      fd934a28
    • Iustin Pop's avatar
      Convert hbal from multiple rounds to a step-method · 7dfaafb1
      Iustin Pop authored
      Currently hbal does multiple rounds, stopping when a rounds doesn't
      bring improvements. With the recent changes to not remove instances from
      the candidate list, this is obsolete as the first round will always run
      to the end of the improvements.
      
      This patch changes this so that the Cluster.checkMove function doesn't
      recurse, but just computes the next best move (as its docstring says).
      This means we can actually incrementally compute and print the solution,
      and this is needed as otherwise an instance could move twice and the
      second time it needs the current placement to compute the exact command
      line and operation needed for the move.
      7dfaafb1
    • Iustin Pop's avatar
      Rework the solution printing in Cluster.hs · ca8258d9
      Iustin Pop authored
      This abstracts the individual placement solution so that it can be used
      independently.
      ca8258d9
  13. Mar 12, 2009
    • Iustin Pop's avatar
      Remove the restriction of one-move-per-round · 0a0f2533
      Iustin Pop authored
      The current code restricts each instance to one move per round. This is
      bad, as an computation restarted in the middle of the solution will have
      a different set of instances to work and will thus lead to a different
      end-solution.
      
      Once this is applied, further rounds are not possible since the first
      round will have tried all instances at its end. As such, the removal of
      the rounds feature will be next.
      
      The code adds a hard-coded 100 moves limit, which for big clusters is
      actually small.
      0a0f2533
    • Iustin Pop's avatar
      Add a header to node lists and print more data · ced859f3
      Iustin Pop authored
      This prints the total memory/disk and also adds a header.
      ced859f3
    • Iustin Pop's avatar
      Rename the maxRes to r_mem · c622fa7c
      Iustin Pop authored
      This is to keep in style with the other memory variables.
      c622fa7c
    • Iustin Pop's avatar
      Display the reserved memory too in node lists · 04247752
      Iustin Pop authored
      This is useful and not easy to compute otherwise.
      04247752
Loading