Skip to content

Commit 093563a

Browse files
committed
fix(metrics): restored prefix default to prod.grafana..
1 parent 0951da9 commit 093563a

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

conf/defaults.ini

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -350,13 +350,13 @@ global_session = -1
350350
# Metrics available at HTTP API Url /api/metrics
351351
[metrics]
352352
enabled = true
353-
interval_seconds = 60
353+
interval_seconds = 10
354354

355355
# Send internal Grafana metrics to graphite
356356
[metrics.graphite]
357357
# Enable by setting the address setting (ex localhost:2003)
358358
address =
359-
prefix = service.grafana.%(instance_name)s.
359+
prefix = prod.grafana.%(instance_name)s.
360360

361361
[grafana_net]
362362
url = https://grafana.net

conf/sample.ini

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -297,18 +297,18 @@ check_for_updates = true
297297
# Metrics available at HTTP API Url /api/metrics
298298
[metrics]
299299
# Disable / Enable internal metrics
300-
enabled = true
300+
;enabled = true
301301

302302
# Publish interval
303-
interval_seconds = 10
303+
;interval_seconds = 10
304304

305305
# Send internal metrics to Graphite
306306
[metrics.graphite]
307307
# Enable by setting the address setting (ex localhost:2003)
308-
address =
309-
prefix = service.grafana.%(instance_name)s.
308+
;address =
309+
;prefix = prod.grafana.%(instance_name)s.
310310

311311
#################################### Internal Grafana Metrics ##########################
312312
# Url used to to import dashboards directly from Grafana.net
313313
[grafana_net]
314-
url = https://grafana.net
314+
;url = https://grafana.net

docs/sources/installation/configuration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ Enable metrics reporting. defaults true. Available via HTTP API `/api/metrics`.
466466

467467
### interval_seconds
468468

469-
Flush/Write interval when sending metrics to external TSDB. Defaults to 60s.
469+
Flush/Write interval when sending metrics to external TSDB. Defaults to 10s.
470470

471471
## [metrics.graphite]
472472
Include this section if you want to send internal Grafana metrics to Graphite.

pkg/metrics/graphite_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ func TestGraphitePublisher(t *testing.T) {
1919
So(err, ShouldBeNil)
2020

2121
sec, err := setting.Cfg.NewSection("metrics.graphite")
22-
sec.NewKey("prefix", "service.grafana.%(instance_name)s.")
22+
sec.NewKey("prefix", "prod.grafana.%(instance_name)s.")
2323
sec.NewKey("address", "localhost:2001")
2424

2525
So(err, ShouldBeNil)
@@ -30,7 +30,7 @@ func TestGraphitePublisher(t *testing.T) {
3030
So(err, ShouldBeNil)
3131
So(publisher, ShouldNotBeNil)
3232

33-
So(publisher.prefix, ShouldEqual, "service.grafana.hostname_with_dots_com.")
33+
So(publisher.prefix, ShouldEqual, "prod.grafana.hostname_with_dots_com.")
3434
So(publisher.address, ShouldEqual, "localhost:2001")
3535
})
3636

@@ -53,7 +53,7 @@ func TestGraphitePublisher(t *testing.T) {
5353
So(err, ShouldBeNil)
5454
So(publisher, ShouldNotBeNil)
5555

56-
So(publisher.prefix, ShouldEqual, "service.grafana.hostname_with_dots_com.")
56+
So(publisher.prefix, ShouldEqual, "prod.grafana.hostname_with_dots_com.")
5757
So(publisher.address, ShouldEqual, "localhost:2001")
5858
})
5959

0 commit comments

Comments
 (0)