LGTM, thanks!

On Tue, Feb 11, 2014 at 5:17 PM, Klaus Aehlig <[email protected]> wrote:

>
> commit 0a1128ecc4d281dc43f6bf8251c8dd162a3bb258
> Merge: d759a02 929efcc
> Author: Klaus Aehlig <[email protected]>
> Date:   Tue Feb 11 17:10:16 2014 +0100
>
>     Merge branch 'stable-2.11' into master
>
>     * stable-2.11
>       Gracefully handle queries for non-existing nodes
>       Consider job-IDs queried for twice only once
>
>     Conflicts:
>         lib/client/gnt_node.py: trivial
>         src/Ganeti/Query/Query.hs: import ALL the functions
>
>     Signed-off-by: Klaus Aehlig <[email protected]>
>
> diff --cc lib/client/gnt_node.py
> index 1ad857e,4e7ab29..9dfef8b
> --- a/lib/client/gnt_node.py
> +++ b/lib/client/gnt_node.py
> @@@ -248,11 -249,15 +248,15 @@@ def AddNode(opts, args)
>       pass
>
>     try:
>  -    output = query_cl.QueryNodes(names=[node],
>  -                                 fields=["name", "sip", "master",
>  -                                         "ndp/ssh_port"],
>  -                                 use_locking=False)
>  +    output = cl.QueryNodes(names=[node],
>  +                           fields=["name", "sip", "master",
>  +                                   "ndp/ssh_port"],
>  +                           use_locking=False)
> -     node_exists, sip, is_master, ssh_port = output[0]
> +     if len(output) == 0:
> +       node_exists = ""
> +       sip = None
> +     else:
> +       node_exists, sip, is_master, ssh_port = output[0]
>     except (errors.OpPrereqError, errors.OpExecError):
>       node_exists = ""
>       sip = None
> diff --cc src/Ganeti/Query/Query.hs
> index b8ce10a,a94cdc0..b0383a3
> --- a/src/Ganeti/Query/Query.hs
> +++ b/src/Ganeti/Query/Query.hs
> @@@ -57,11 -57,10 +57,11 @@@ module Ganeti.Query.Quer
>       ) where
>
>   import Control.DeepSeq
> - import Control.Monad (filterM, foldM, unless)
>  -import Control.Monad (filterM, foldM, liftM)
> ++import Control.Monad (filterM, foldM, liftM, unless)
>  +import Control.Monad.IO.Class
>   import Control.Monad.Trans (lift)
>   import qualified Data.Foldable as Foldable
> - import Data.List (intercalate)
> + import Data.List (intercalate, nub)
>   import Data.Maybe (fromMaybe)
>   import qualified Data.Map as Map
>   import qualified Text.JSON as J
>
>
> --
> Klaus Aehlig
> Google Germany GmbH, Dienerstr. 12, 80331 Muenchen
> Registergericht und -nummer: Hamburg, HRB 86891
> Sitz der Gesellschaft: Hamburg
> Geschaeftsfuehrer: Graham Law, Christine Elizabeth Flores
>



Hrvoje Ribicic
Ganeti Engineering
Google Germany GmbH
Dienerstr. 12, 80331, München

Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Graham Law, Christine Elizabeth Flores
Steuernummer: 48/725/00206
Umsatzsteueridentifikationsnummer: DE813741370

Reply via email to