summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-statistics/htdocs/luci-static/resources
diff options
context:
space:
mode:
authorHannu Nyman <hannu.nyman@iki.fi>2020-12-18 17:41:18 +0200
committerHannu Nyman <hannu.nyman@iki.fi>2020-12-18 17:41:18 +0200
commitb43a5da43e16f016e4fe22425970a649b9c66fdb (patch)
tree838ed7e693bb5221a72fcd62c19882498c5e826c /applications/luci-app-statistics/htdocs/luci-static/resources
parent15757dd5b18f9e00ba3c9b38af4d46702a31fe33 (diff)
luci-app-statistics: shorten delay at graph endpoint to 15s
Shorten the visible delay at the statistics graph endpoint from 60 seconds to 15 seconds. The 60s delay was recently added as a way to remove a possible visible gap at the end of the hourly graph due to absence of recent data. Default data collection interval is 30s, so that 60s guarantees that there is data upto to the end of the graph. However, that 60s makes any recent activity to get displayed really slowly, after a 60-89 second delay. Shortening the gap to 15s, half of the default data collection period, should balance things: * Half of the time there may be a really narrow gap visible and half of the time there is no gap at all. * The most recent displayed data point is from 15-44 seconds ago (instead of 60-89 seconds ago). Neither 15 or 60 seconds makes any impact to the longer graphs. To accommodate to possibly shorter timespans, and to avoid the occasional wrong data series selected for longer period graphs (see #4065) the endpoint delay might be relative to the timespan. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
Diffstat (limited to 'applications/luci-app-statistics/htdocs/luci-static/resources')
-rw-r--r--applications/luci-app-statistics/htdocs/luci-static/resources/statistics/rrdtool.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/applications/luci-app-statistics/htdocs/luci-static/resources/statistics/rrdtool.js b/applications/luci-app-statistics/htdocs/luci-static/resources/statistics/rrdtool.js
index 4c3c8da5cd..322eee137c 100644
--- a/applications/luci-app-statistics/htdocs/luci-static/resources/statistics/rrdtool.js
+++ b/applications/luci-app-statistics/htdocs/luci-static/resources/statistics/rrdtool.js
@@ -334,7 +334,7 @@ return baseclass.extend({
var cmdline = [
'graph', '-', '-a', 'PNG',
'-s', 'NOW-%s'.format(timespan || this.opts.timespan),
- '-e', 'NOW-60',
+ '-e', 'NOW-15',
'-w', width || this.opts.width,
'-h', height || this.opts.height
];