Commit 9dcab5e3 authored by Martin Schorb's avatar Martin Schorb
Browse files

sparkslurm status

parent c33a7d16
......@@ -78,6 +78,8 @@ def update_status(n,click,run_state,logfile,module,thispage):
if not link == '':
r_status['status'],status_href = link.split('__')
status_href = 'http://' + status_href
if not 'Problem' in r_status['status']:
if 'Startup' in r_status['status']:
status_href += ':' + params.spark_port
......
......@@ -186,6 +186,8 @@ def cluster_status(run_state):
sp_masterfile = os.path.join(logfile.rsplit(os.extsep)[0],'spark-master-' + str(j_id),'master')
if not os.path.exists(sp_masterfile): return ['launch'],link
with open(sp_masterfile) as f: sp_master=f.read().strip('\n')
link = '__' + sp_master
......@@ -234,6 +236,8 @@ def cluster_status(run_state):
out_stat.append('pending')
elif 'CANCELLED' in slurm_stat:
out_stat.append('cancelled')
else:
out_stat.append('launch')
return out_stat[0],link
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment