metrics: memory utilization
This commit is contained in:
@@ -60,14 +60,14 @@ def average_response_latency_in_ns(connection):
|
||||
return round(result[0],1)
|
||||
|
||||
@metric
|
||||
def memory_utilisation(connection):
|
||||
def memory_utilisation_percent(connection):
|
||||
cursor = connection.cursor()
|
||||
cursor.execute(""" SELECT sum(DataStrobeEnd - DataStrobeBegin) FROM transactions """)
|
||||
active = cursor.fetchone()
|
||||
cursor = connection.cursor()
|
||||
cursor.execute(""" SELECT max(DataStrobeEnd) FROM Transactions """)
|
||||
total = cursor.fetchone()
|
||||
return str(active[0]/total[0]*100)+"%"
|
||||
return (active[0]/total[0])*100
|
||||
|
||||
|
||||
def refreshMissDecision(connection,calculatedMetrics):
|
||||
|
||||
Reference in New Issue
Block a user