diff --git a/CHANGELOG.md b/CHANGELOG.md index e3498a00ec3..47dd6d821b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - **Removed PhantomJS**: PhantomJS was deprecated in [Grafana v6.4](https://grafana.com/docs/grafana/latest/guides/whats-new-in-v6-4/#phantomjs-deprecation) and starting from Grafana v7.0.0, all PhantomJS support has been removed. This means that Grafana no longer ships with a built-in image renderer, and we advise you to install the [Grafana Image Renderer plugin](https://grafana.com/grafana/plugins/grafana-image-renderer). - **Docker**: Our Ubuntu based images have been upgraded to Ubuntu [20.04 LTS](https://releases.ubuntu.com/20.04/). +- **Dashboard**: A global minimum dashboard refresh interval is now enforced and defaults to 5 seconds. # 6.7.3 (2020-04-23) diff --git a/conf/defaults.ini b/conf/defaults.ini index 37250cb8cde..e36da638225 100644 --- a/conf/defaults.ini +++ b/conf/defaults.ini @@ -230,9 +230,9 @@ snapshot_remove_expired = true # Number dashboard versions to keep (per dashboard). Default: 20, Minimum: 1 versions_to_keep = 20 -# Minimum dashboard refresh interval. When set, this will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is not set/unrestricted. +# Minimum dashboard refresh interval. When set, this will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is 5 seconds. # The interval string is a possibly signed sequence of decimal numbers, followed by a unit suffix (ms, s, m, h, d), e.g. 30s or 1m. -min_refresh_interval = +min_refresh_interval = 5s #################################### Users ############################### [users] diff --git a/conf/sample.ini b/conf/sample.ini index 8d1d007d7d6..650e3f51f94 100644 --- a/conf/sample.ini +++ b/conf/sample.ini @@ -229,9 +229,9 @@ # Number dashboard versions to keep (per dashboard). Default: 20, Minimum: 1 ;versions_to_keep = 20 -# Minimum dashboard refresh interval. When set, this will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is not set/unrestricted. +# Minimum dashboard refresh interval. When set, this will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is 5 seconds. # The interval string is a possibly signed sequence of decimal numbers, followed by a unit suffix (ms, s, m, h, d), e.g. 30s or 1m. -;min_refresh_interval = +;min_refresh_interval = 5s #################################### Users ############################### [users] diff --git a/docs/sources/installation/configuration.md b/docs/sources/installation/configuration.md index 0aa0a69258f..b495f2187c4 100644 --- a/docs/sources/installation/configuration.md +++ b/docs/sources/installation/configuration.md @@ -510,7 +510,7 @@ Number dashboard versions to keep (per dashboard). Default: `20`, Minimum: `1`. > Only available in Grafana v6.7+. -When set, this will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is not set/unrestricted. +This will restrict users to set the refresh interval of a dashboard lower than given interval. Per default this is 5 seconds. The interval string is a possibly signed sequence of decimal numbers, followed by a unit suffix (ms, s, m, h, d), e.g. `30s` or `1m`. ## [dashboards.json] diff --git a/docs/sources/installation/upgrading.md b/docs/sources/installation/upgrading.md index 66e0600ce10..ed03a6c53bd 100755 --- a/docs/sources/installation/upgrading.md +++ b/docs/sources/installation/upgrading.md @@ -244,3 +244,7 @@ change the `[security]` setting `cookie_secure` to `true` and use HTTPS when `co ### PhantomJS removed PhantomJS was deprecated in [Grafana v6.4](https://grafana.com/docs/grafana/latest/guides/whats-new-in-v6-4/#phantomjs-deprecation) and starting from Grafana v7.0.0, all PhantomJS support has been removed. This means that Grafana no longer ships with a built-in image renderer, and we adwise you to install the [Grafana Image Renderer plugin](https://grafana.com/grafana/plugins/grafana-image-renderer). + +### Dashboard minimum refresh interval enforced + +A global minimum dashboard refresh interval is now enforced and defaults to 5 seconds. Read more [here]({{< relref "configuration/#min-refresh-interval" >}}) about this setting. diff --git a/pkg/setting/setting.go b/pkg/setting/setting.go index e65377ccf3b..15d343b5c54 100644 --- a/pkg/setting/setting.go +++ b/pkg/setting/setting.go @@ -768,7 +768,7 @@ func (cfg *Cfg) Load(args *CommandLineArgs) error { // read dashboard settings dashboards := iniFile.Section("dashboards") DashboardVersionsToKeep = dashboards.Key("versions_to_keep").MustInt(20) - MinRefreshInterval, err = valueAsString(dashboards, "min_refresh_interval", "") + MinRefreshInterval, err = valueAsString(dashboards, "min_refresh_interval", "5s") if err != nil { return err }