Skip to content
Snippets Groups Projects
Commit cc2bea8b authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

ganeti-masterd: Remove unused locking code

Reviewed-by: iustinp, ultrotter
parent 96cb3986
No related branches found
No related tags found
No related merge requests found
......@@ -288,28 +288,21 @@ def PoolWorker(worker_id, incoming_queue, context):
if item is None:
break
logging.debug("worker %s processing job %s", worker_id, item.data.job_id)
#utils.Lock('cmd')
proc = mcpu.Processor(context, feedback=lambda x: None)
try:
proc = mcpu.Processor(context, feedback=lambda x: None)
try:
JobRunner(proc, item, context)
except errors.GenericError, err:
msg = "ganeti exception"
logging.error(msg, exc_info=err)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
except Exception, err:
msg = "unhandled exception"
logging.error(msg, exc_info=err)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
except:
msg = "unhandled unknown exception"
logging.error(msg, exc_info=True)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
finally:
#utils.Unlock('cmd')
#utils.LockCleanup()
pass
JobRunner(proc, item, context)
except errors.GenericError, err:
msg = "ganeti exception"
logging.error(msg, exc_info=err)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
except Exception, err:
msg = "unhandled exception"
logging.error(msg, exc_info=err)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
except:
msg = "unhandled unknown exception"
logging.error(msg, exc_info=True)
item.SetStatus(opcodes.Job.STATUS_FAIL, result=[msg])
logging.debug("worker %s finish job %s", worker_id, item.data.job_id)
logging.debug("worker %s exiting", worker_id)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment