community
Steve L. Nyemba 6 years ago
parent 805df9bdc9
commit 7f858fc505

@ -106,7 +106,7 @@ class apps(analytics) :
r.append( {"x":[row['crash'],row['idle'],row['running']],"labels":['Crash','Idle','Running'],"title":row['node'],"date":row['date']})
# q.append({"x":[[row['cpu'],row['mem']]],"labels":["CPU","RAM"],"title":"Resources","date":row['date'],"title":row['node'],"series":[ 'CPU','RAM' ]})
q.append({"x":[[row['cpu'],0],[0,row['mem']]],"labels":["",""],"title":"Resources","date":row['date'],"title":row['node'],"series":[ 'CPU','RAM' ],"ylabel":"% Resource Used"})
q.append({"x":[[row['cpu'],0],[0,row['mem']]],"labels":["",""],"title":"","date":row['date'],"title":row['node'],"series":[ 'CPU','RAM' ],"ylabel":"% Resource Used"})
self.set('status',r)
self.set('resource',q)
@ -140,7 +140,7 @@ class folders(analytics):
else:
max_size = 0
self.set('max_size',max_size)
for id in logs :
for id in logs :
row = pd.DataFrame(logs[id]['log'])
size = row.size_in_kb.mean() * .001
@ -177,6 +177,3 @@ class didact():
self.cache['nodes'] = list(set(r) - set([None]))
def get(self,id):
return self.cache[id] if id in self.cache else None
config = {"args":{"uid":"cus_D2x3ItYNfWjSY3", "dbname":"smart-top","uri":"http://admin:@dm1n@dev.the-phi.com:5985"},"type":"CouchdbReader"}
p = folders(config = config,key="cus_D2x3ItYNfWjSY3")

Loading…
Cancel
Save