The jid load comes in directly, not as 'load' key. Should return the mongo record directly without accessing keys

This commit is contained in:
rforkosh 2016-06-12 18:01:22 -05:00
parent cf81afab47
commit d622133a49

View File

@ -223,8 +223,7 @@ def get_load(jid):
Return the load associated with a given job id
'''
conn, mdb = _get_conn(ret=None)
ret = mdb.jobs.find_one({'jid': jid}, {'_id': 0})
return ret['load']
return mdb.jobs.find_one({'jid': jid}, {'_id': 0})
def get_jid(jid):