Skip to content
Snippets Groups Projects
  1. Jan 18, 2013
  2. Jan 17, 2013
  3. Jan 16, 2013
  4. Jan 15, 2013
  5. Jan 14, 2013
    • Dato Simó's avatar
      Loader.hs: ignore expired ArSuspended policies · ef947a42
      Dato Simó authored
      
      At the moment, because 'mergeData' is pure, it may set instance auto-repair
      policies that are of the form `ArSuspended $ Until timestamp_in_the_past`.
      If later on the auto-repair tool notices this, it has lost access to what
      would be the next-in-line policy to use (and would have to re-parse all
      tags again).
      
      To avoid this, we pass the current time to 'mergeData' from ExtLoader.hs,
      and we propagate it to Loader.getArPolicy. ExtLoader.loadExternalData is in
      the IO monad, so it has ready access to getClockTime.
      
      A few other places were calling 'mergeData' directly. For Hscan.hs and
      IAlloc.hs, we add appropriate calls to getClockTime. For files under test/,
      we use a current time of 0.
      
      Signed-off-by: default avatarDato Simó <dato@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      ef947a42
    • Dato Simó's avatar
      Loader.hs: set instance auto-repair policy in mergeData · 55416810
      Dato Simó authored
      
      'getArPolicy' and 'setArPolicy' follow the precedence rules introduced in
      b1eb71c7: within an object, the most restrictive tag wins; across object,
      the nearest tag wins.
      
      Signed-off-by: default avatarDato Simó <dato@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      55416810
    • Dato Simó's avatar
      design-autorepair.rst: clarify tag precedence and conflict · b1eb71c7
      Dato Simó authored
      
      This commit clarifies one particular point of the auto-repair workflow:
      what to do when multiple, conflicting administrator-set tags exist in an
      object; and how tags at different levels (cluster, node group and instance)
      interact.
      
      For conflict within an object, we choose to always let the most restrictive
      tag win (i.e. the least destructive repair, and the longest suspension
      time). For tags at different levels, we follow a simple "nearest tag wins"
      rule.
      
      Signed-off-by: default avatarDato Simó <dato@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      b1eb71c7
Loading