Author: pmoravec
Date: Thu Oct 23 14:11:43 2014
New Revision: 1633818
URL: http://svn.apache.org/r1633818
Log:
QPID-6177: qpid-tool should print warning when initial connection to broker
fails
Modified:
qpid/trunk/qpid/tools/src/py/qpid-tool
Modified: qpid/trunk/qpid/tools/src/py/qpid-tool
URL:
http://svn.apache.org/viewvc/qpid/trunk/qpid/tools/src/py/qpid-tool?rev=1633818&r1=1633817&r2=1633818&view=diff
==============================================================================
--- qpid/trunk/qpid/tools/src/py/qpid-tool (original)
+++ qpid/trunk/qpid/tools/src/py/qpid-tool Thu Oct 23 14:11:43 2014
@@ -29,8 +29,7 @@ from cmd import Cmd
from shlex import split
from threading import Lock
from time import strftime, gmtime
-from qpid.disp import Display
-from qpid.peer import Closed
+from qpidtoollibs import Display
from qmf.console import Session, Console, SchemaClass, ObjectId
class Mcli(Cmd):
@@ -594,6 +593,12 @@ class QmfData(Console):
#=====================
# Methods from Console
#=====================
+ def brokerConnectionFailed(self, broker):
+ """ Invoked when a connection to a broker fails """
+ if self.first_connect:
+ self.first_connect = None
+ print "Failed to connect: ", broker.error
+
def brokerConnected(self, broker):
""" Invoked when a connection is established to a broker """
try:
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]