(subject changed)
>>> Dejan Muhamedagic <deja...@fastmail.fm> schrieb am 08.11.2016 um 21:19 in
Nachricht <20161108201951.GA4946@tuttle.homenet>:

[...]
> crmsh has an option (-w) to wait for the PE to settle after
> committing configuration changes.

I didn't know that, but thinking about scripting, it would be more helpful to 
have:
*       either a separate "wait" command (maybe with a timeout) to wait for the 
PE to finish
*       or "wait" ("-wait"?) as command option, like in "reprobe wait <node>"

I see that there is an option "wait" that is a global toggle, but 
crmsh/command.py already has a wait(fn) that seems to do what I proposed 
(Actually I cannot read Python):
def wait(fn):
    '''
    A command with this decorator will
    force the interactive shell to wait
    for the command to complete.

        @command
        @wait
        def do_bigop(self, cmd, args):
            ...
    '''
    setattr(fn, '_wait', True)
    return fn

Opinions?

Regards,
Ulrich



_______________________________________________
Users mailing list: Users@clusterlabs.org
http://clusterlabs.org/mailman/listinfo/users

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org

Reply via email to