[Pkg-ganeti-devel] [ganeti] 61/165: Add an option --exit-on-missing-mond-data

Apollon Oikonomopoulos apoikos at moszumanska.debian.org
Tue Aug 11 13:53:13 UTC 2015


This is an automated email from the git hooks/post-receive script.

apoikos pushed a commit to branch master
in repository ganeti.

commit 30917176383ee27089b4ecb6da0f938b72d302f9
Author: Klaus Aehlig <aehlig at google.com>
Date:   Tue Feb 24 10:57:49 2015 +0100

    Add an option --exit-on-missing-mond-data
    
    When dynamic data is not available, htools normally
    proceed with a best guess based on the static information.
    In a purely dynamic balancing set up this might, however,
    be counterproductive. This option will tell htools to
    exit in not all needed data is available.
    
    Signed-off-by: Klaus Aehlig <aehlig at google.com>
    Reviewed-by: Petr Pudlak <pudlak at google.com>
---
 src/Ganeti/HTools/CLI.hs | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/src/Ganeti/HTools/CLI.hs b/src/Ganeti/HTools/CLI.hs
index 1f16dbd..289d17c 100644
--- a/src/Ganeti/HTools/CLI.hs
+++ b/src/Ganeti/HTools/CLI.hs
@@ -62,6 +62,7 @@ module Ganeti.HTools.CLI
   , oMonDDataFile
   , oMonDXen
   , oEvacMode
+  , oMonDExitMissing
   , oFirstJobGroup
   , oRestrictedMigrate
   , oExInst
@@ -152,6 +153,8 @@ data Options = Options
                                      -- by MonDs
   , optMonDXen     :: Bool           -- ^ Should Xen-specific collectors be
                                      -- considered (only if MonD is queried)
+  , optMonDExitMissing :: Bool       -- ^ If the program should exit on missing
+                                     -- MonD data
   , optEvacMode    :: Bool           -- ^ Enable evacuation mode
   , optRestrictedMigrate :: Bool     -- ^ Disallow replace-primary moves
   , optExInst      :: [String]       -- ^ Instances to be excluded
@@ -219,6 +222,7 @@ defaultOptions  = Options
   , optMonD        = False
   , optMonDFile = Nothing
   , optMonDXen     = False
+  , optMonDExitMissing = False
   , optEvacMode    = False
   , optRestrictedMigrate = False
   , optExInst      = []
@@ -349,6 +353,13 @@ oMonDXen =
     "also consider xen-specific collectors in MonD queries",
     OptComplNone)
 
+oMonDExitMissing :: OptType
+oMonDExitMissing =
+  (Option "" ["exit-on-missing-mond-data"]
+    (NoArg (\ opts -> Ok opts { optMonDExitMissing = True }))
+    "abort if the data available from the monitoring daemons is incomplete",
+    OptComplNone)
+
 oDiskTemplate :: OptType
 oDiskTemplate =
   (Option "" ["disk-template"]

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ganeti/ganeti.git



More information about the Pkg-ganeti-devel mailing list