[DOC] Fix style issues and add videos to tracing and profiling shared files (#81215)
Co-authored-by: Jack Baldry <jack.baldry@grafana.com> Co-authored-by: Ryan Perry <Rperry2174@gmail.com> Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>
This commit is contained in:
co-authored by
Jack Baldry
Ryan Perry
Clayton Cornell
parent
2a734a9e3f
commit
da8eb8faa5
@@ -21,7 +21,7 @@ weight: 1150
|
||||
|
||||
# Grafana Pyroscope data source
|
||||
|
||||
Formerly Phlare data source, now Grafana Pyroscope, a horizontally scalable, highly-available, multi-tenant, OSS, continuous profiling aggregation system. Add it as a data source, and you are ready to query your profiles in [Explore][explore].
|
||||
Grafana Pyroscope is a horizontally scalable, highly available, multi-tenant, OSS, continuous profiling aggregation system. Add it as a data source, and you are ready to query your profiles in [Explore][explore].
|
||||
|
||||
## Configure the Grafana Pyroscope data source
|
||||
|
||||
@@ -30,59 +30,78 @@ To configure basic settings for the data source, complete the following steps:
|
||||
1. Click **Connections** in the left-side menu.
|
||||
1. Under Your connections, click **Data sources**.
|
||||
1. Enter `Grafana Pyroscope` in the search bar.
|
||||
1. Click **Grafana Pyroscope**.
|
||||
|
||||
The **Settings** tab of the data source is displayed.
|
||||
1. Click **Grafana Pyroscope** to display the **Settings** tab of the data source.
|
||||
|
||||
1. Set the data source's basic configuration options:
|
||||
|
||||
| Name | Description |
|
||||
| -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| `Name` | A name to specify the data source in panels, queries, and Explore. |
|
||||
| `Default` | The default data source will be pre-selected for new panels. |
|
||||
| `URL` | The URL of the Grafana Pyroscope or Phlare instance, e.g., `http://localhost:4100` |
|
||||
| `Basic Auth` | Enable basic authentication to the data source. |
|
||||
| `User` | User name for basic authentication. |
|
||||
| `Password` | Password for basic authentication. |
|
||||
| `Minimal step` | Used for queries returning timeseries data. Phlare backend, similar to Prometheus, scrapes profiles at certain intervals. To prevent querying at smaller interval use Minimal step same or higher than your Phlare scrape interval. For Pyroscope backend this prevents returning too many data points to the front end. |
|
||||
| Name | Description |
|
||||
| -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| `Name` | A name to specify the data source in panels, queries, and Explore. |
|
||||
| `Default` | The default data source will be pre-selected for new panels. |
|
||||
| `URL` | The URL of the Grafana Pyroscope instance, for example, `http://localhost:4100`. |
|
||||
| `Basic Auth` | Enable basic authentication to the data source. |
|
||||
| `User` | User name for basic authentication. |
|
||||
| `Password` | Password for basic authentication. |
|
||||
| `Minimal step` | Used for queries returning timeseries data. The Pyroscope backend, similar to Prometheus, scrapes profiles at certain intervals. To prevent querying at smaller interval, use Minimal step same or higher than your Pyroscope scrape interval. This prevents returning too many data points to the frontend. |
|
||||
|
||||
### Traces to profiles
|
||||
|
||||
You can link profile and tracing data using your Pyroscope data source with the Tempo data source.
|
||||
For more information, refer to the [Traces to profile section][configure-tempo-data-source] of the Tempo data source documentation.
|
||||
|
||||
{{< youtube id="AG8VzfFMLxo" >}}
|
||||
|
||||
## Querying
|
||||
|
||||
### Query Editor
|
||||
You can query your profiling data using the query editor.
|
||||
|
||||

|
||||
### Query editor
|
||||
|
||||
Query editor gives you access to a profile type selector, a label selector, and collapsible options.
|
||||
The query editor gives you access to a profile type selector, a label selector, and collapsible options.
|
||||
|
||||

|
||||

|
||||
|
||||
Select a profile type from the drop-down menu. While the label selector can be left empty to query all profiles without filtering by labels, the profile type or app must be selected for the query to be valid. Grafana does not show any data if the profile type or app isn’t selected when a query is run.
|
||||
To access the query editor:
|
||||
|
||||

|
||||
1. Sign into Grafana or Grafana Cloud.
|
||||
1. Select your Pyroscope data source.
|
||||
1. From the menu, choose **Explore**.
|
||||
|
||||
Use the labels selector input to filter by labels. Pyroscope uses similar syntax to Prometheus to filter labels. Refer to [Pyroscope documentation](https://grafana.com/docs/pyroscope/latest/) for available operators and syntax.
|
||||
1. Select a profile type from the drop-down menu.
|
||||
|
||||

|
||||
{{< figure src="/media/docs/pyroscope/query-editor/select-profile.png" class="docs-image--no-shadow" max-width="450px" caption="Profile selector" >}}
|
||||
|
||||
Options section contains a switch for Query Type and Group by.
|
||||
1. Use the labels selector input to filter by labels. Pyroscope uses similar syntax to Prometheus to filter labels.
|
||||
Refer to [Pyroscope documentation](https://grafana.com/docs/pyroscope/latest/) for available operators and syntax.
|
||||
|
||||
Select a query type to return the profile data which can be shown in the [Flame Graph][flame-graph], metric data visualized in a graph, or both. You can only select both options in a dashboard, because panels allow only one visualization.
|
||||
While the label selector can be left empty to query all profiles without filtering by labels, the profile type or app must be selected for the query to be valid.
|
||||
|
||||
Group by allows you to group metric data by a specified label. Without any Group by label, metric data is aggregated over all the labels into single time series. You can use multiple labels to group by. Group by has only an effect on the metric data and does not change the profile data results.
|
||||
Grafana doesn't show any data if the profile type or app isn’t selected when a query runs.
|
||||
|
||||

|
||||
|
||||
1. Expand the **Options** section to view **Query Type** and **Group by**.
|
||||

|
||||
|
||||
1. Select a query type to return the profile data which can be shown in the [Flame Graph][flame-graph], metric data visualized in a graph, or both. You can only select both options in a dashboard, because panels allow only one visualization.
|
||||
|
||||
**Group by** allows you to group metric data by a specified label. Without any **Group by** label, metric data is aggregated over all the labels into single time series. You can use multiple labels to group by. Group by has only an effect on the metric data and doesn't change the profile data results.
|
||||
|
||||
### Profiles query results
|
||||
|
||||
Profiles can be visualized in a flame graph. See the [Flame Graph documentation][flame-graph] to learn about the visualization and its features.
|
||||
|
||||

|
||||

|
||||
|
||||
Pyroscope returns profiles aggregated over a selected time range, and the absolute values in the flame graph grow as the time range gets bigger while keeping the relative values meaningful. You can zoom in on the time range to get a higher granularity profile up to the point of a single scrape interval.
|
||||
Pyroscope returns profiles aggregated over a selected time range.
|
||||
The absolute values in the flame graph grow as the time range gets bigger while keeping the relative values meaningful.
|
||||
You can zoom in on the time range to get a higher granularity profile up to the point of a single scrape interval.
|
||||
|
||||
### Metrics query results
|
||||
|
||||
Metrics results represent the aggregated sum value over time of the selected profile type.
|
||||
|
||||

|
||||

|
||||
|
||||
This allows you to quickly see any spikes in the value of the scraped profiles and zoom in to a particular time range.
|
||||
|
||||
@@ -90,7 +109,7 @@ This allows you to quickly see any spikes in the value of the scraped profiles a
|
||||
|
||||
You can modify the Grafana configuration files to provision the Grafana Pyroscope data source. To learn more, and to view the available provisioning settings, see [provisioning documentation][provisioning-data-sources].
|
||||
|
||||
Here is an example config:
|
||||
Here is an example configuration:
|
||||
|
||||
```yaml
|
||||
apiVersion: 1
|
||||
@@ -112,4 +131,7 @@ datasources:
|
||||
|
||||
[provisioning-data-sources]: "/docs/grafana/ -> /docs/grafana/<GRAFANA VERSION>/administration/provisioning#datasources"
|
||||
[provisioning-data-sources]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA VERSION>/administration/provisioning#datasources"
|
||||
|
||||
[configure-tempo-data-source]: "/docs/grafana/ -> /docs/grafana/<GRAFANA VERSION>/datasources/tempo/configure-tempo-data-source"
|
||||
[configure-tempo-data-source]: "/docs/grafana-cloud/ -> docs/grafana-cloud/connect-externally-hosted/data-sources/tempo/configure-tempo-data-source"
|
||||
{{% /docs/reference %}}
|
||||
|
||||
@@ -26,6 +26,10 @@ For instructions on how to add a data source to Grafana, refer to the [administr
|
||||
Only users with the organization administrator role can add data sources.
|
||||
Administrators can also [configure the data source via YAML][configure-tempo-data-source] with Grafana's provisioning system.
|
||||
|
||||
This video explains how to add data sources, including Loki, Tempo, and Mimir, to Grafana and Grafana Cloud. Tempo data source set up starts at 4:58 in the video.
|
||||
|
||||
{{< youtube id="cqHO0oYW6Ic" start="298" >}}
|
||||
|
||||
Once you've added the data source, you can [configure it]({{< relref "./configure-tempo-data-source/" >}}) so that your Grafana instance's users can create queries in its [query editor]({{< relref "./query-editor/" >}}) when they [build dashboards][build-dashboards] and use [Explore][explore].
|
||||
|
||||
{{< section withDescriptions="true">}}
|
||||
|
||||
@@ -35,7 +35,11 @@ To configure basic settings for the Tempo data source, complete the following st
|
||||
| **User** | Sets the user name for basic authentication. |
|
||||
| **Password** | Sets the password for basic authentication. |
|
||||
|
||||
You can also configure settings specific to the Tempo data source. These options are described in the sections below.
|
||||
You can also configure settings specific to the Tempo data source.
|
||||
|
||||
This video explains how to add data sources, including Loki, Tempo, and Mimir, to Grafana and Grafana Cloud. Tempo data source set up starts at 4:58 in the video.
|
||||
|
||||
{{< youtube id="cqHO0oYW6Ic" start="298" >}}
|
||||
|
||||
## Trace to logs
|
||||
|
||||
|
||||
Reference in New Issue
Block a user