diff options
| author | Alan Conway <aconway@apache.org> | 2012-05-22 18:11:20 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2012-05-22 18:11:20 +0000 |
| commit | d5a3080ffaae79c9613347a0eeed0b1d330c40f8 (patch) | |
| tree | 55a1325a7f0856765274f6fd1600d2767b578caa /tools | |
| parent | 766498cd02fb29942e8c3279d0bb89f23a553ae4 (diff) | |
| download | qpid-python-d5a3080ffaae79c9613347a0eeed0b1d330c40f8.tar.gz | |
QPID-3603: Renamed brokers and public-brokers to brokers-url and public-url for clarity.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1341581 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'tools')
| -rwxr-xr-x | tools/src/py/qpid-ha | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tools/src/py/qpid-ha b/tools/src/py/qpid-ha index 6fee0204e7..36f08ba397 100755 --- a/tools/src/py/qpid-ha +++ b/tools/src/py/qpid-ha @@ -93,30 +93,31 @@ class SetCmd(Command): Command.__init__(self, "set", "Set HA configuration settings") def add(optname, metavar, type, help): self.op.add_option(optname, metavar=metavar, type=type, help=help, action="store") - add("--brokers", "<url>", "string", "HA brokers use <url> to connect to each other") - add("--public-brokers", "<url>", "string", "Clients use <url> to connect to HA brokers") + add("--brokers-url", "<url>", "string", "URL with address of each broker in the cluster. Used by brokers to connect to each other.") + add("--public-url", "<url>", "string", "URL advertised to clients to connect to the cluster. May be a list or a VIP.") add("--backups", "<n>", "int", "Expect <n> backups to be running"), def do_execute(self, qmf_broker, ha_broker, opts, args): - if (opts.brokers): qmf_broker._method("setBrokers", {"url":opts.brokers}, HA_BROKER) - if (opts.public_brokers): qmf_broker._method("setPublicBrokers", {"url":opts.public_brokers}, HA_BROKER) + if (opts.brokers_url): qmf_broker._method("setBrokersUrl", {"url":opts.brokers_url}, HA_BROKER) + if (opts.public_url): qmf_broker._method("setPublicUrl", {"url":opts.public_url}, HA_BROKER) if (opts.backups): qmf_broker._method("setExpectedBackups", {"expectedBackups":opts.backups}, HA_BROKER) SetCmd() class QueryCmd(Command): def __init__(self): - Command.__init__(self, "query", "Print HA configuration settings") + Command.__init__(self, "query", "Print HA configuration and status") def do_execute(self, qmf_broker, ha_broker, opts, args): hb = ha_broker for x in [("Status:", hb.status), - ("Brokers URL:", hb.brokers), - ("Public URL:", hb.publicBrokers), + ("Brokers URL:", hb.brokersUrl), + ("Public URL:", hb.publicUrl), ("Expected Backups:", hb.expectedBackups), ("Replicate: ", hb.replicateDefault) ]: print "%-20s %s"%(x[0], x[1]) + QueryCmd() def print_usage(prog): |
