diff --git a/Zotlabs/Module/Perfstats.php b/Zotlabs/Module/Perfstats.php index cea08bde3..3ccd1bbc0 100644 --- a/Zotlabs/Module/Perfstats.php +++ b/Zotlabs/Module/Perfstats.php @@ -64,6 +64,11 @@ class Perfstats extends Controller $stats['queueworkers'] = $qwstats->active; $stats['workqsz'] = $qwstats->size; + // Return a timestamp, so that it is possible to infer + // changes of the stats over time. A resolution of + // seconds should be good enough for our purposes. + $stats['ts'] = time(); + return $stats; } diff --git a/Zotlabs/Widget/Channel_activities.php b/Zotlabs/Widget/Channel_activities.php index af94d6235..fde46d1dd 100644 --- a/Zotlabs/Widget/Channel_activities.php +++ b/Zotlabs/Widget/Channel_activities.php @@ -264,11 +264,12 @@ class Channel_activities { 'outqueue' => 0, 'queueworkers' => 0, 'workqsz' => 0, + 'ts' => time(), ], 'tpl' => 'system_status_widget.tpl', 'labels' => [ 'loadavg' => t('Load average'), - 'dbqueries' => t('DB queries'), + 'dbqueries' => t('DB queries/sec'), 'outqueue' => t('Output queue'), 'queueworkers' => t('Queue workers'), 'workqsz' => t('Work queue size'), diff --git a/view/tpl/system_status_widget.tpl b/view/tpl/system_status_widget.tpl index b36455e9a..0a129a34b 100644 --- a/view/tpl/system_status_widget.tpl +++ b/view/tpl/system_status_widget.tpl @@ -5,31 +5,48 @@
| {{$labels.$id|escape}}: | {{$item|escape}} |