Revision 9ae49f27
b/daemons/ganeti-noded | ||
---|---|---|
77 | 77 |
params = simplejson.loads(body) |
78 | 78 |
result = method(params) |
79 | 79 |
payload = simplejson.dumps(result) |
80 |
except errors.QuitGanetiException, err: |
|
81 |
global _EXIT_GANETI_NODED |
|
82 |
_EXIT_GANETI_NODED = True |
|
83 |
if isinstance(err, tuple) and len(err) == 2: |
|
84 |
if err[0]: |
|
85 |
self.send_error(500, "Error: %s" % str(err[1])) |
|
86 |
else: |
|
87 |
payload = simplejson.dumps(err[1]) |
|
88 |
else: |
|
89 |
self.log_message('GanetiQuitException Usage Error') |
|
90 |
self.send_error(500, "Error: %s" % str(err)) |
|
80 | 91 |
except Exception, err: |
81 | 92 |
self.send_error(500, "Error: %s" % str(err)) |
82 | 93 |
return False |
Also available in: Unified diff