Commit 4f73cfc9 authored by Iustin Pop's avatar Iustin Pop
Browse files

Merge branch 'devel-2.7'



* devel-2.7:
  Change hbal behaviour in case of early exit
  Fix build/sphinx_ext.py with tuple defaults for op params
  Fix bug in man build rule
  Fix hscolour style sheet building
Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarMichele Tartara <mtartara@google.com>
parents 777e8b6f 2d6bdcc5
......@@ -1317,7 +1317,7 @@ man/%.gen: man/%.rst lib/query.py lib/build/sphinx_ext.py \
man/%.7.in man/%.8.in man/%.1.in: man/%.gen man/footer.rst
@test -n "$(PANDOC)" || \
{ echo 'pandoc' not found during configure; exit 1; }
set -o pipefail ; \
set -o pipefail -e; \
trap 'echo auto-removing $@; rm $@' EXIT; \
$(PANDOC) -s -f rst -t man $< man/footer.rst | \
sed -e 's/\\@/@/g' > $@; \
......@@ -1847,10 +1847,8 @@ $(APIDOC_HS_DIR)/index.html: $(HS_LIBTESTBUILT_SRCS) Makefile
rm -rf $(APIDOC_HS_DIR)/*
for i in $(ALL_APIDOC_HS_DIRS); do \
@mkdir_p@ $$i; \
$(HSCOLOUR) -print-css > $$i/hscolour.css; \
done
$(HSCOLOUR) -print-css > $(APIDOC_HS_DIR)/Ganeti/hscolour.css
$(LN_S) ../hscolour.css $(APIDOC_HS_DIR)/Ganeti/HTools/hscolour.css
$(LN_S) ../hscolour.css $(APIDOC_HS_DIR)/Ganeti/Confd/hscolour.css
set -e ; \
export LC_ALL=en_US.UTF-8; \
OPTGHC="--optghc=-isrc --optghc=-itest/hs"; \
......
......@@ -98,6 +98,10 @@ Version 2.7.0 beta1
- Instance renames of LVM-based instances will now update the LV tags
(which can be used to recover the instance-to-LV mapping in case of
emergencies)
- ``hbal`` will now exit with status 0 if, during job execution over
LUXI, early exit has been requested and all jobs are successful;
before, exit status 1 was used, which cannot be differentiated from
"job error" case
Version 2.6.2
......
#!/bin/bash
#
# Copyright (C) 2012 Google Inc.
# Copyright (C) 2012, 2013 Google Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -20,5 +20,5 @@
set -e
! grep -F -q '\[em]' "$1" || \
! grep -F '\[em]' "$1" || \
{ echo "Unescaped dashes found in $1, use \\-- instead of --" 1>&2; exit 1; }
#
#
# Copyright (C) 2011, 2012 Google Inc.
# Copyright (C) 2011, 2012, 2013 Google Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -168,15 +168,15 @@ def _BuildOpcodeParams(op_id, include, exclude, alias):
has_test = not (test is None or test is ht.NoType)
buf = StringIO()
buf.write("``%s``" % rapi_name)
buf.write("``%s``" % (rapi_name,))
if has_default or has_test:
buf.write(" (")
if has_default:
buf.write("defaults to ``%s``" % default)
buf.write("defaults to ``%s``" % (default,))
if has_test:
buf.write(", ")
if has_test:
buf.write("must be ``%s``" % test)
buf.write("must be ``%s``" % (test,))
buf.write(")")
yield buf.getvalue()
......@@ -335,8 +335,8 @@ def BuildValuesDoc(values):
"""
for name, doc in values:
assert len(doc.splitlines()) == 1
yield "``%s``" % name
yield " %s" % doc
yield "``%s``" % (name,)
yield " %s" % (doc,)
def _ManPageNodeClass(*args, **kwargs):
......
......@@ -53,7 +53,7 @@ respective state, ``--pending`` includes both.
CHANGE-PRIORITY
~~~~~~~~~~~~~~~
| **change-priority** --priority {low | normal | high}
| **change-priority** \--priority {low | normal | high}
| {[\--force] {\--pending | \--queued | \--waiting} | *job-id* ...}
Changes the priority of one or multiple pending jobs. Jobs currently
......
......@@ -26,13 +26,13 @@ ADD
~~~
| **add**
| [--network=*NETWORK*]
| [--gateway=*GATEWAY*]
| [--add-reserved-ips=*RESERVEDIPS*]
| [--network6=*NETWORK6*]
| [--gateway6=*GATEWAY6*]
| [--mac-prefix=*MACPREFIX*]
| [--submit]
| [\--network=*NETWORK*]
| [\--gateway=*GATEWAY*]
| [\--add-reserved-ips=*RESERVEDIPS*]
| [\--network6=*NETWORK6*]
| [\--gateway6=*GATEWAY6*]
| [\--mac-prefix=*MACPREFIX*]
| [\--submit]
| {*network*}
Creates a new network with the given name. The network will be unused
......@@ -62,13 +62,13 @@ MODIFY
~~~~~~
| **modify**
| [--gateway=*GATEWAY*]
| [--add-reserved-ips=*RESERVEDIPS*]
| [--remove-reserved-ips=*RESERVEDIPS*]
| [--network6=*NETWORK6*]
| [--gateway6=*GATEWAY6*]
| [--mac-prefix=*MACPREFIX*]
| [--submit]
| [\--gateway=*GATEWAY*]
| [\--add-reserved-ips=*RESERVEDIPS*]
| [\--remove-reserved-ips=*RESERVEDIPS*]
| [\--network6=*NETWORK6*]
| [\--gateway6=*GATEWAY6*]
| [\--mac-prefix=*MACPREFIX*]
| [\--submit]
| {*network*}
Modifies parameters from the network.
......@@ -83,7 +83,7 @@ options.
REMOVE
~~~~~~
| **remove** [--submit] {*network*}
| **remove** [\--submit] {*network*}
Deletes the indicated network, which must be not connected to any node group.
......@@ -92,7 +92,7 @@ See **ganeti**\(7) for a description of ``--submit`` and other common options.
LIST
~~~~
| **list** [--no-headers] [--separator=*SEPARATOR*] [-v]
| **list** [\--no-headers] [\--separator=*SEPARATOR*] [-v]
| [-o *[+]FIELD,...*] [network...]
Lists all existing networks in the cluster. If no group names are given,
......
......@@ -585,7 +585,7 @@ annotated in the command line output.
RESTRICTED-COMMAND
~~~~~~~~~~~~~~~~~~
| **restricted-command** [-M] [--sync]
| **restricted-command** [-M] [\--sync]
| { -g *group* *command* | *command* *nodes*... }
Executes a restricted command on the specified nodes. Restricted commands are
......
......@@ -400,16 +400,18 @@ in two ways:
- by sending a ``SIGINT`` (``^C``), hbal will register the termination
request, and will wait until the currently submitted jobs finish, at
which point it will exit (with exit code 1)
which point it will exit (with exit code 0 if all jobs finished
correctly, otherwise with exit code 1 as usual)
- by sending a ``SIGTERM``, hbal will immediately exit (with exit code
2); it is the responsibility of the user to follow up with Ganeti the
result of the currently-executing jobs
2\); it is the responsibility of the user to follow up with Ganeti
and check the result of the currently-executing jobs
Note that in any situation, it's perfectly safe to kill hbal, either via
the above signals or via any other signal (e.g. ``SIGQUIT``,
``SIGKILL``), since the jobs themselves are processed by Ganeti whereas
hbal (after submission) only watches their progression. In this case,
the use will again have to query Ganeti for job results.
the user will have to query Ganeti for job results.
EXIT STATUS
-----------
......
......@@ -186,8 +186,10 @@ execCancelWrapper _ _ _ _ _ [] = return $ Ok ()
execCancelWrapper anno master nl il cref alljss = do
cancel <- readIORef cref
if cancel > 0
then return . Bad $ "Exiting early due to user request, " ++
show (length alljss) ++ " jobset(s) remaining."
then do
putStrLn $ "Exiting early due to user request, " ++
show (length alljss) ++ " jobset(s) remaining."
return $ Ok ()
else execJobSet anno master nl il cref alljss
-- | Execute an entire jobset.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment