Skip to content

Commit cbe366f

Browse files
397 Add doc for anonymous usage stats (#4104) (#4108)
* 397 Add doc for anonymous usage stats * Specify exactly what usage statistics Pyroscope reports * Add links to the anonymous usage statistics page * Run "make reference-help" --------- Co-authored-by: Aleksandar Petrov <[email protected]> Co-authored-by: Christian Simon <[email protected]> (cherry picked from commit 70a2dbd) Co-authored-by: Kim Nylander <[email protected]>
1 parent f616a03 commit cbe366f

File tree

8 files changed

+90
-8
lines changed

8 files changed

+90
-8
lines changed

cmd/pyroscope/help-all.txt.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1066,7 +1066,7 @@ Usage of ./pyroscope:
10661066
-tracing.profiling-enabled
10671067
[experimental] Set to true to enable profiling integration.
10681068
-usage-stats.enabled
1069-
Enable anonymous usage reporting. (default true)
1069+
Enable anonymous usage statistics collection. For more details about usage statistics, refer to https://grafana.com/docs/pyroscope/latest/configure-server/anonymous-usage-statistics-reporting/ (default true)
10701070
-validation.enforce-labels-order
10711071
Enforce labels order optimization.
10721072
-validation.max-label-names-per-series int

cmd/pyroscope/help.txt.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ Usage of ./pyroscope:
390390
-tracing.enabled
391391
Set to false to disable tracing. (default true)
392392
-usage-stats.enabled
393-
Enable anonymous usage reporting. (default true)
393+
Enable anonymous usage statistics collection. For more details about usage statistics, refer to https://grafana.com/docs/pyroscope/latest/configure-server/anonymous-usage-statistics-reporting/ (default true)
394394
-validation.enforce-labels-order
395395
Enforce labels order optimization.
396396
-validation.max-label-names-per-series int
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
---
2+
3+
description: Learn about Grafana Pyroscope anonymous usage statistics reporting
4+
menuTitle: Anonymous usage statistics reporting
5+
title: About Grafana Pyroscope anonymous usage statistics reporting
6+
weight: 30
7+
---
8+
9+
# About Grafana Pyroscope anonymous usage statistics reporting
10+
11+
Grafana Pyroscope includes a system that optionally and anonymously reports non-sensitive, non-personally identifiable information about the running Pyroscope cluster to a remote statistics server.
12+
Pyroscope maintainers use this anonymous information to learn more about how the open source community runs Pyroscope and what the Pyroscope team should focus on when working on the next features and documentation improvements.
13+
14+
The anonymous usage statistics reporting is **enabled by default**.
15+
You can opt-out setting the CLI flag `-usage-stats.enabled=false` or its respective YAML configuration option.
16+
17+
## The statistics server
18+
19+
When usage statistics reporting is enabled, information is collected by a server that Grafana Labs runs. Statistics are collected at `https://stats.grafana.org`.
20+
21+
## Which information is collected
22+
23+
When the usage statistics reporting is enabled, Grafana Pyroscope collects the following information:
24+
25+
- Information about the **Pyroscope cluster and version**:
26+
- A unique, randomly-generated Pyroscope cluster identifier, such as `3749b5e2-b727-4107-95ae-172abac27496`.
27+
- The timestamp when the anonymous usage statistics reporting was enabled for the first time, and the cluster identifier was created.
28+
- The Pyroscope version, such as `1.13.1`.
29+
- The Pyroscope branch, revision, and Golang version that was used to build the binary.
30+
- Information about the **environment** where Pyroscope is running:
31+
- The operating system, such as `linux`.
32+
- The architecture, such as `amd64`.
33+
- The Pyroscope memory utilization and number of goroutines.
34+
- The number of logical CPU cores available to the Pyroscope process.
35+
- Information about the Pyroscope **configuration**:
36+
- The `-target` parameter value, such as `all` when running Pyroscope in monolithic mode.
37+
- The `-storage.backend` value, such as `s3`.
38+
- The `-distributor.replication-factor` value, such as `3`.
39+
- Information about the Pyroscope **cluster scale**:
40+
- Distributor:
41+
- Bytes received.
42+
- Profiles received with breakdown by profile type and programming language.
43+
- Profile sizes with breakdown by programming language.
44+
- Ingester:
45+
- Number of active tenants.
46+
47+
48+
{{< admonition type="note" >}}
49+
Pyroscope maintainers commit to keeping the list of tracked information updated over time, and reporting any change both via the CHANGELOG and the release notes.
50+
{{< /admonition >}}
51+
52+
## Disable the anonymous usage statistics reporting
53+
54+
If possible, we ask you to keep the usage reporting feature enabled and help us understand more about how the open source community runs Pyroscope.
55+
In case you want to opt-out from anonymous usage statistics reporting, set the CLI flag `-usage-stats.enabled=false` or change the following YAML configuration:
56+
57+
```yaml
58+
analytics:
59+
reporting_enabled: false
60+
```

docs/sources/configure-server/reference-configuration-parameters/index.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -269,10 +269,10 @@ self_profiling:
269269
# CLI flag: -auth.multitenancy-enabled
270270
[multitenancy_enabled: <boolean> | default = false]
271271

272-
analytics:
273-
# Enable anonymous usage reporting.
274-
# CLI flag: -usage-stats.enabled
275-
[reporting_enabled: <boolean> | default = true]
272+
# The analytics block configures usage statistics collection. For more details
273+
# about usage statistics, refer to [Anonymous usage statistics
274+
# reporting](../anonymous-usage-statistics-reporting)
275+
[analytics: <analytics>]
276276

277277
# Prints the application banner at startup.
278278
# CLI flag: -config.show_banner
@@ -2471,4 +2471,15 @@ The `filesystem_storage_backend` block configures the usage of local file system
24712471
[dir: <string> | default = "./data-shared"]
24722472
```
24732473

2474+
### analytics
2475+
2476+
The `analytics` block configures usage statistics collection. For more details about usage statistics, refer to [Anonymous usage statistics reporting](../anonymous-usage-statistics-reporting)
2477+
2478+
```yaml
2479+
# Enable anonymous usage statistics collection. For more details about usage
2480+
# statistics, refer to
2481+
# https://grafana.com/docs/pyroscope/latest/configure-server/anonymous-usage-statistics-reporting/
2482+
# CLI flag: -usage-stats.enabled
2483+
[reporting_enabled: <boolean> | default = true]
24742484
```
2485+

docs/sources/configure-server/reference-configuration-parameters/index.template

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,3 @@ where `default_value` is the value to use if the environment variable is undefin
6060

6161
{{ .ConfigFile }}
6262

63-
```

docs/sources/get-started/_index.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ For more information on the different ways to deploy Pyroscope, see [Pyroscope d
2727

2828
Verify that you have installed [Docker](https://docs.docker.com/engine/install/).
2929

30+
{{< admonition type="note" >}}
31+
Pyroscope includes a system that optionally and anonymously reports non-sensitive, non-personally identifiable information about the running Pyroscope cluster to a remote statistics server to help Pyroscope maintainers understand how the open source community runs Pyroscope.
32+
33+
To opt out, refer to [Disable the anonymous usage statistics reporting](../configure-server/anonymous-usage-statistics-reporting#disable-the-anonymous-usage-statistics-reporting).
34+
{{< /admonition >}}
35+
3036
## Download and configure Pyroscope
3137

3238
1. Download Pyroscope.

pkg/usagestats/reporter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ type Config struct {
4646

4747
// RegisterFlags adds the flags required to config this to the given FlagSet
4848
func (cfg *Config) RegisterFlags(f *flag.FlagSet) {
49-
f.BoolVar(&cfg.Enabled, "usage-stats.enabled", true, "Enable anonymous usage reporting.")
49+
f.BoolVar(&cfg.Enabled, "usage-stats.enabled", true, "Enable anonymous usage statistics collection. For more details about usage statistics, refer to https://grafana.com/docs/pyroscope/latest/configure-server/anonymous-usage-statistics-reporting/")
5050
}
5151

5252
type Reporter struct {

tools/doc-generator/parse/root_blocks.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ import (
2222
"github.com/grafana/pyroscope/pkg/querier/worker"
2323
"github.com/grafana/pyroscope/pkg/scheduler"
2424
"github.com/grafana/pyroscope/pkg/storegateway"
25+
"github.com/grafana/pyroscope/pkg/usagestats"
2526
"github.com/grafana/pyroscope/pkg/validation"
2627
)
2728

@@ -113,4 +114,9 @@ var RootBlocks = []RootBlock{
113114
StructType: reflect.TypeOf(filesystem.Config{}),
114115
Desc: "The filesystem_storage_backend block configures the usage of local file system as object storage backend.",
115116
},
117+
{
118+
Name: "analytics",
119+
StructType: reflect.TypeOf(usagestats.Config{}),
120+
Desc: "The analytics block configures usage statistics collection. For more details about usage statistics, refer to [Anonymous usage statistics reporting](../anonymous-usage-statistics-reporting)",
121+
},
116122
}

0 commit comments

Comments
 (0)