From: Thierry Parmentelat Date: Mon, 9 Jan 2012 12:30:43 +0000 (+0100) Subject: adapted for SfaServerProxy X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=1c3fb4530de7d74aa9338874c0e8db3ca1dc83f1;p=infrastructure.git adapted for SfaServerProxy --- diff --git a/scripts/check_sfa_peer.py b/scripts/check_sfa_peer.py index 3e22197..568b57a 100755 --- a/scripts/check_sfa_peer.py +++ b/scripts/check_sfa_peer.py @@ -14,7 +14,7 @@ ALL = { } import signal,sys -import sfa.util.xmlrpcprotocol as xmlrpcprotocol +from sfa.client.sfaserverproxy import SfaServerProxy class TimeOutException(Exception): pass @@ -27,7 +27,7 @@ def timeout(signum, frame): def get_version(url): signal.signal(signal.SIGALRM, timeout) signal.alarm(10) - server=xmlrpcprotocol.get_server(url, KEY_FILE, CERT_FILE) + server=SfaServerProxy(url, KEY_FILE, CERT_FILE) try: version = server.GetVersion() except Exception, why: @@ -75,4 +75,5 @@ if __name__ == '__main__': if (error > 0): sys.exit(1) - + else: + sys.exit(0)