Commit 1e4c62a7 by Torkel Ödegaard

updated server reporting

parent 526f3e1a
...@@ -6,13 +6,14 @@ import ( ...@@ -6,13 +6,14 @@ import (
"net/http" "net/http"
"time" "time"
"github.com/grafana/grafana/pkg/log"
"github.com/grafana/grafana/pkg/setting" "github.com/grafana/grafana/pkg/setting"
) )
func StartUsageReportLoop() chan struct{} { func StartUsageReportLoop() chan struct{} {
M_Instance_Start.Inc(1) M_Instance_Start.Inc(1)
ticker := time.NewTicker(10 * time.Minute) ticker := time.NewTicker(24 * time.Hour)
for { for {
select { select {
case <-ticker.C: case <-ticker.C:
...@@ -22,6 +23,8 @@ func StartUsageReportLoop() chan struct{} { ...@@ -22,6 +23,8 @@ func StartUsageReportLoop() chan struct{} {
} }
func sendUsageStats() { func sendUsageStats() {
log.Trace("Sending anonymous usage stats to stats.grafana.org")
metrics := map[string]interface{}{} metrics := map[string]interface{}{}
report := map[string]interface{}{ report := map[string]interface{}{
"version": setting.BuildVersion, "version": setting.BuildVersion,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment