<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>TestData data source on Grafana Labs</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/</link><description>Recent content in TestData data source on Grafana Labs</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="/docs/grafana/v13.0/datasources/testdata/index.xml" rel="self" type="application/rss+xml"/><item><title>Configure the TestData data source</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/configure/</link><pubDate>Tue, 14 Apr 2026 14:59:56 +0000</pubDate><guid>https://grafana.com/docs/grafana/v13.0/datasources/testdata/configure/</guid><content><![CDATA[&lt;h1 id=&#34;configure-the-testdata-data-source&#34;&gt;Configure the TestData data source&lt;/h1&gt;
&lt;p&gt;This document explains how to configure the TestData data source. TestData requires no external connection or authentication, so configuration is minimal.&lt;/p&gt;
&lt;p&gt;For general information on managing data sources, refer to 
    &lt;a href=&#34;/docs/grafana/v13.0/administration/data-source-management/&#34;&gt;Data source management&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;before-you-begin&#34;&gt;Before you begin&lt;/h2&gt;
&lt;p&gt;You must have the Organization administrator role to add and configure data sources.&lt;/p&gt;
&lt;h2 id=&#34;add-the-data-source&#34;&gt;Add the data source&lt;/h2&gt;
&lt;p&gt;To add the TestData data source:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Click &lt;strong&gt;Connections&lt;/strong&gt; in the left-side menu.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Add new connection&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Type &lt;code&gt;TestData&lt;/code&gt; in the search bar.&lt;/li&gt;
&lt;li&gt;Select &lt;strong&gt;TestData&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Add new data source&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Grafana takes you to the &lt;strong&gt;Settings&lt;/strong&gt; tab.&lt;/p&gt;
&lt;h2 id=&#34;configuration-options&#34;&gt;Configuration options&lt;/h2&gt;
&lt;p&gt;TestData doesn&amp;rsquo;t require any settings beyond the standard options common to all data sources.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Setting&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Name&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Sets the name you use to refer to the data source in panels and queries.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Default&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Defines whether this data source is pre-selected for new panels.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;verify-the-connection&#34;&gt;Verify the connection&lt;/h2&gt;
&lt;p&gt;Click &lt;strong&gt;Save &amp;amp; test&lt;/strong&gt; to verify the data source. A successful test displays the message:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Data source is working&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;If the test fails, refer to 
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/troubleshooting/&#34;&gt;Troubleshoot TestData&lt;/a&gt; for common issues and solutions.&lt;/p&gt;
&lt;h2 id=&#34;provision-the-data-source&#34;&gt;Provision the data source&lt;/h2&gt;
&lt;p&gt;You can define and configure the data source in YAML files as part of Grafana&amp;rsquo;s provisioning system. For more information about provisioning, refer to 
    &lt;a href=&#34;/docs/grafana/v13.0/administration/provisioning/#data-sources&#34;&gt;Provisioning data sources&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;TestData doesn&amp;rsquo;t require any &lt;code&gt;jsonData&lt;/code&gt; or &lt;code&gt;secureJsonData&lt;/code&gt; fields.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;YAML example&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;YAML&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-yaml&#34;&gt;apiVersion: 1

datasources:
  - name: TestData
    type: grafana-testdata-datasource
    access: proxy&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;h2 id=&#34;provision-with-terraform&#34;&gt;Provision with Terraform&lt;/h2&gt;
&lt;p&gt;To provision the data source with Terraform, use the &lt;a href=&#34;https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/data_source&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;&lt;code&gt;grafana_data_source&lt;/code&gt; resource&lt;/a&gt;:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;hcl&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-hcl&#34;&gt;resource &amp;#34;grafana_data_source&amp;#34; &amp;#34;testdata&amp;#34; {
  name = &amp;#34;TestData&amp;#34;
  type = &amp;#34;grafana-testdata-datasource&amp;#34;
}&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;For all available configuration options, refer to the &lt;a href=&#34;https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/data_source&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Grafana provider data source resource documentation&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;next-steps&#34;&gt;Next steps&lt;/h2&gt;
&lt;p&gt;After configuring your TestData data source, you can:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/query-editor/&#34;&gt;Write queries&lt;/a&gt; using the 30 available scenarios to generate simulated data.&lt;/li&gt;
&lt;li&gt;
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/template-variables/&#34;&gt;Use template variables&lt;/a&gt; to create dynamic, reusable dashboards.&lt;/li&gt;
&lt;li&gt;
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/alerting/&#34;&gt;Set up alerting&lt;/a&gt; to prototype and test alert rules with simulated data.&lt;/li&gt;
&lt;li&gt;
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/troubleshooting/&#34;&gt;Troubleshoot issues&lt;/a&gt; if you encounter problems with your data source.&lt;/li&gt;
&lt;/ul&gt;
]]></content><description>&lt;h1 id="configure-the-testdata-data-source">Configure the TestData data source&lt;/h1>
&lt;p>This document explains how to configure the TestData data source. TestData requires no external connection or authentication, so configuration is minimal.&lt;/p></description></item><item><title>TestData query editor</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/query-editor/</link><pubDate>Tue, 14 Apr 2026 14:59:56 +0000</pubDate><guid>https://grafana.com/docs/grafana/v13.0/datasources/testdata/query-editor/</guid><content><![CDATA[&lt;h1 id=&#34;testdata-query-editor&#34;&gt;TestData query editor&lt;/h1&gt;
&lt;p&gt;Instead of a traditional query language, the TestData data source uses &lt;strong&gt;scenarios&lt;/strong&gt; to generate simulated data. Each scenario produces a different type of data suited for testing specific visualizations, behaviors, or edge cases. TestData includes 30 scenarios covering time series, logs, traces, graphs, streaming, and error simulation.&lt;/p&gt;
&lt;p&gt;Use scenarios to:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Prototype dashboards&lt;/strong&gt; without connecting to a real data source.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Reproduce bugs&lt;/strong&gt; with controlled, deterministic data that other developers can replicate.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Test panel behavior&lt;/strong&gt; with edge cases like empty results, timestamps outside the visible range, or mixed data and errors.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Validate alerting pipelines&lt;/strong&gt; using predictable patterns that fire and resolve on a known schedule.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Simulate streaming&lt;/strong&gt; to verify how panels handle real-time data updates.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;To build a query, select a scenario from the &lt;strong&gt;Scenario&lt;/strong&gt; drop-down. The query editor updates to show fields specific to that scenario. Click &lt;strong&gt;Run queries&lt;/strong&gt; or use the keyboard shortcut to execute.&lt;/p&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;Some scenarios run entirely in the browser (Streaming Client, Grafana Live, Grafana API, Steps, No Data Points). These scenarios don&amp;rsquo;t send queries to the backend, which means they can&amp;rsquo;t be used with 
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/alerting/&#34;&gt;Grafana Alerting&lt;/a&gt; or in any context that requires server-side evaluation.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

&lt;h2 id=&#34;scenario-reference&#34;&gt;Scenario reference&lt;/h2&gt;
&lt;p&gt;The scenarios are organized into the following categories. Use the table below to find the right scenario for your use case.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Scenario&lt;/th&gt;
              &lt;th&gt;Category&lt;/th&gt;
              &lt;th&gt;Purpose&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#random-walk&#34;&gt;Random Walk&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Random walk time series (default scenario).&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#random-walk-table&#34;&gt;Random Walk Table&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Random walk in table format with &lt;code&gt;Enum&lt;/code&gt; state.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#random-walk-with-error&#34;&gt;Random Walk (with error)&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Random walk that also returns an error.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#predictable-pulse&#34;&gt;Predictable Pulse&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Repeating on/off wave based on absolute time.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#predictable-csv-wave&#34;&gt;Predictable CSV Wave&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Custom repeating waveforms from CSV values.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#simulation&#34;&gt;Simulation&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Continuous simulation engine (flight, sine, tank).&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#usa-generated-data&#34;&gt;USA generated data&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data generation&lt;/td&gt;
              &lt;td&gt;Multi-dimensional data with US state dimensions.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#csv-content&#34;&gt;CSV Content&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Paste or type CSV data directly.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#steps&#34;&gt;Steps&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Step-function data from CSV input.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#csv-file&#34;&gt;CSV File&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Select from built-in CSV data files.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#csv-metric-values&#34;&gt;CSV Metric Values&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Time series from comma-separated values.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#raw-frames&#34;&gt;Raw Frames&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Define data frames in JSON format.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#load-apache-arrow-data&#34;&gt;Load Apache Arrow Data&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Render base64-encoded Arrow payloads.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#table-static&#34;&gt;Table Static&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Manual input&lt;/td&gt;
              &lt;td&gt;Static table with predefined columns.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#logs&#34;&gt;Logs&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Simulated log data with random levels.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#node-graph&#34;&gt;Node Graph&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Data for node graph visualizations.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#flame-graph&#34;&gt;Flame Graph&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Data for flame graph visualizations.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#trace&#34;&gt;Trace&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Simulated distributed trace data.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#annotations&#34;&gt;Annotations&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Annotation data points.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#exponential-heatmap-bucket-data&#34;&gt;Exponential heatmap bucket data&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Heatmap data with exponential buckets.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#linear-heatmap-bucket-data&#34;&gt;Linear heatmap bucket data&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Visualization testing&lt;/td&gt;
              &lt;td&gt;Heatmap data with linear buckets.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#streaming-client&#34;&gt;Streaming Client&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Streaming&lt;/td&gt;
              &lt;td&gt;Browser-side streaming (signal, logs, traces).&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#grafana-live&#34;&gt;Grafana Live&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Streaming&lt;/td&gt;
              &lt;td&gt;Server-side streaming via live channels.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#grafana-api&#34;&gt;Grafana API&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Data retrieval&lt;/td&gt;
              &lt;td&gt;Fetch data from internal Grafana endpoints.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#conditional-error&#34;&gt;Conditional Error&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Error testing&lt;/td&gt;
              &lt;td&gt;Configurable error or CSV data.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#error-with-source&#34;&gt;Error with source&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Error testing&lt;/td&gt;
              &lt;td&gt;Error with plugin or downstream classification.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#no-data-points&#34;&gt;No Data Points&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Error testing&lt;/td&gt;
              &lt;td&gt;Empty result with no data.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#datapoints-outside-range&#34;&gt;Data Points Outside Range&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Error testing&lt;/td&gt;
              &lt;td&gt;Data point outside the visible time range.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#slow-query&#34;&gt;Slow Query&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Error testing&lt;/td&gt;
              &lt;td&gt;Configurable delay before returning data.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;a href=&#34;#query-metadata&#34;&gt;Query Metadata&lt;/a&gt;&lt;/td&gt;
              &lt;td&gt;Metadata&lt;/td&gt;
              &lt;td&gt;Returns query context metadata.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;shared-query-options&#34;&gt;Shared query options&lt;/h2&gt;
&lt;p&gt;Every scenario displays the &lt;strong&gt;Scenario&lt;/strong&gt; drop-down. Most scenarios also show an &lt;strong&gt;Alias&lt;/strong&gt; field and, when the scenario defines a default, a &lt;strong&gt;String Input&lt;/strong&gt; field. Some scenarios expose additional shared controls. Scenario-specific options appear below these fields.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Scenario&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Drop-down to select the data generation type. Scenarios are listed alphabetically.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Alias&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Optional display name for the series. Hidden for the Simulation and Annotations scenarios. Supports the special values &lt;code&gt;__server_names&lt;/code&gt; and &lt;code&gt;__house_locations&lt;/code&gt; to use built-in name sets.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;String Input&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Text field shown when the selected scenario provides a default string value. Used differently by each scenario.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Labels&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Available for Random Walk and Predictable Pulse. Set labels using key=value syntax, for example &lt;code&gt;key=&amp;quot;value&amp;quot;, key2=&amp;quot;value2&amp;quot;&lt;/code&gt;. Use &lt;code&gt;$seriesIndex&lt;/code&gt; in a value to insert the series index.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Drop percent&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Available for CSV Content and CSV File. Drops a random percentage (0-100) of data points from the result.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;data-generation-scenarios&#34;&gt;Data generation scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios produce time-series data with configurable parameters.&lt;/p&gt;
&lt;h3 id=&#34;random-walk&#34;&gt;Random Walk&lt;/h3&gt;
&lt;p&gt;Generates random walk time-series data. This is the default scenario.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Series count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of series to generate. Default: &lt;code&gt;1&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Start value&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Initial value for the walk. Default: auto (random).&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Min&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Minimum value the walk can reach. Default: none.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Max&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Maximum value the walk can reach. Default: none.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Spread&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Controls how far each step can deviate. Default: &lt;code&gt;1&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Noise&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Adds noise to each data point. Default: &lt;code&gt;0&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Drop (%)&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Percentage of points to randomly exclude. Default: &lt;code&gt;0&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;random-walk-table&#34;&gt;Random Walk Table&lt;/h3&gt;
&lt;p&gt;Generates random walk data in table format with columns for Time, Value, Min, Max, Info, and State. The State column uses an &lt;code&gt;enum&lt;/code&gt; field with values Unknown, Up, and Down. Optionally includes null values when &lt;strong&gt;withNil&lt;/strong&gt; is enabled.&lt;/p&gt;
&lt;h3 id=&#34;random-walk-with-error&#34;&gt;Random Walk (with error)&lt;/h3&gt;
&lt;p&gt;Generates random walk time-series data and also returns an error in the response. Use this to test how panels handle data responses that contain both data and errors.&lt;/p&gt;
&lt;h3 id=&#34;predictable-pulse&#34;&gt;Predictable Pulse&lt;/h3&gt;
&lt;p&gt;Generates a predictable pulse wave based on absolute time from the epoch, making it reproducible across runs.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Step&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Seconds between data points. Default: &lt;code&gt;60&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;On Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of data points at the start of each cycle that use the on value. Default: &lt;code&gt;3&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Off Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of data points in each cycle that use the off value. Default: &lt;code&gt;3&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;On Value&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;The value for &amp;ldquo;on&amp;rdquo; data points. Can be a number, &lt;code&gt;null&lt;/code&gt;, or &lt;code&gt;nan&lt;/code&gt;. Default: &lt;code&gt;2&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Off Value&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;The value for &amp;ldquo;off&amp;rdquo; data points. Can be a number, &lt;code&gt;null&lt;/code&gt;, or &lt;code&gt;nan&lt;/code&gt;. Default: &lt;code&gt;1&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;The wave cycles at &lt;code&gt;Step * (On Count &#43; Off Count)&lt;/code&gt; seconds. Timestamps align evenly on the step interval.&lt;/p&gt;
&lt;p&gt;With the defaults (Step=60, On Count=3, Off Count=3), the wave completes a full cycle every 6 minutes. The on value (&lt;code&gt;2&lt;/code&gt;) holds for the first 3 data points, then the off value (&lt;code&gt;1&lt;/code&gt;) holds for the next 3.&lt;/p&gt;
&lt;h3 id=&#34;predictable-csv-wave&#34;&gt;Predictable CSV Wave&lt;/h3&gt;
&lt;p&gt;Generates one or more predictable waves from CSV-defined values. Each wave cycles through its comma-separated values at a fixed time step.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Values&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Comma-separated numeric values for the wave. Supports &lt;code&gt;null&lt;/code&gt; and &lt;code&gt;nan&lt;/code&gt;. Default: &lt;code&gt;0,0,2,2,1,1&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Step&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Seconds between data points. Default: &lt;code&gt;60&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Name&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Optional name for the series.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Labels&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Optional labels in key=value format.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Click the &lt;strong&gt;&#43;&lt;/strong&gt; button on the last wave row to add another wave. Click the &lt;strong&gt;-&lt;/strong&gt; button on any other row to remove it.&lt;/p&gt;
&lt;p&gt;For example, to create two overlapping waves for comparison:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Wave 1: Values &lt;code&gt;0,1,2,3,4,5&lt;/code&gt;, Step &lt;code&gt;60&lt;/code&gt;, Name &lt;code&gt;rising&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Wave 2: Values &lt;code&gt;5,4,3,2,1,0&lt;/code&gt;, Step &lt;code&gt;60&lt;/code&gt;, Name &lt;code&gt;falling&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;simulation&#34;&gt;Simulation&lt;/h3&gt;
&lt;p&gt;Runs a simulation engine that generates data continuously. Simulation supports streaming data through Grafana Live.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Simulation&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Simulation type: &lt;code&gt;Flight&lt;/code&gt; (circling flight path), &lt;code&gt;Sine&lt;/code&gt; (sine wave), or &lt;code&gt;Tank&lt;/code&gt; (fill and drain a water tank).&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Stream&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Toggle to stream data through Grafana Live instead of returning a static result.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Interval&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Tick frequency in Hz. Default: &lt;code&gt;10&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Last&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Toggle to return only the most recent value instead of the full time range.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;UID&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Optional unique identifier. Allows multiple instances of the same simulation type to run concurrently.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;usa-generated-data&#34;&gt;USA generated data&lt;/h3&gt;
&lt;p&gt;Generates data with US state dimensions. Useful for testing geo-map visualizations and multi-dimensional data.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Mode&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Data format: &lt;code&gt;values-as-rows&lt;/code&gt;, &lt;code&gt;values-as-fields&lt;/code&gt;, &lt;code&gt;values-as-labeled-fields&lt;/code&gt;, &lt;code&gt;timeseries&lt;/code&gt;, or &lt;code&gt;timeseries-wide&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Period&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Time period for data generation. Default: &lt;code&gt;30m&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Fields&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Fields to include: &lt;code&gt;foo&lt;/code&gt;, &lt;code&gt;bar&lt;/code&gt;, &lt;code&gt;baz&lt;/code&gt;. Default: all.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;States&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;US state codes to include (for example, &lt;code&gt;CA&lt;/code&gt;, &lt;code&gt;NY&lt;/code&gt;, &lt;code&gt;TX&lt;/code&gt;). Default: all 50 states plus DC.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;manual-input-scenarios&#34;&gt;Manual input scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios let you provide your own data directly instead of generating it.&lt;/p&gt;
&lt;h3 id=&#34;csv-content&#34;&gt;CSV Content&lt;/h3&gt;
&lt;p&gt;Provides a text editor where you paste or type CSV data directly. The first row is treated as headers. Use the &lt;strong&gt;Drop percent&lt;/strong&gt; field to randomly exclude a percentage of data points.&lt;/p&gt;
&lt;p&gt;For example, enter the following to create a time series with two value columns:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Time,Temperature,Humidity
2024-01-01 00:00:00,22.5,45
2024-01-01 01:00:00,21.8,48
2024-01-01 02:00:00,20.1,52&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;h3 id=&#34;steps&#34;&gt;Steps&lt;/h3&gt;
&lt;p&gt;Provides a CSV text area (the same editor as CSV Content) for defining step-function data. The default content is &lt;code&gt;a&lt;/code&gt;, &lt;code&gt;b&lt;/code&gt;, &lt;code&gt;c&lt;/code&gt;. This scenario is handled entirely in the browser.&lt;/p&gt;
&lt;h3 id=&#34;csv-file&#34;&gt;CSV File&lt;/h3&gt;
&lt;p&gt;Selects from a set of built-in CSV data files. Use the &lt;strong&gt;Drop percent&lt;/strong&gt; field to randomly exclude a percentage of data points.&lt;/p&gt;
&lt;p&gt;Available files:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;flight_info_by_state.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;population_by_state.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;gdp_per_capita.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;js_libraries.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ohlc_dogecoin.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;weight_height.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;browser_marketshare.csv&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;automobiles.csv&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;csv-metric-values&#34;&gt;CSV Metric Values&lt;/h3&gt;
&lt;p&gt;Generates time-series data from comma-separated values entered in the &lt;strong&gt;String Input&lt;/strong&gt; field. Values are evenly distributed across the selected time range. Default: &lt;code&gt;1,20,90,30,5,0&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;For example, with the default values and a 6-hour time range, the six values (&lt;code&gt;1&lt;/code&gt;, &lt;code&gt;20&lt;/code&gt;, &lt;code&gt;90&lt;/code&gt;, &lt;code&gt;30&lt;/code&gt;, &lt;code&gt;5&lt;/code&gt;, &lt;code&gt;0&lt;/code&gt;) are spread across the range at equal intervals.&lt;/p&gt;
&lt;h3 id=&#34;raw-frames&#34;&gt;Raw Frames&lt;/h3&gt;
&lt;p&gt;Provides a JSON editor for defining data frames directly. The editor accepts the Grafana data frame JSON format and includes paste helpers for panel JSON and raw query results.&lt;/p&gt;
&lt;h3 id=&#34;load-apache-arrow-data&#34;&gt;Load Apache Arrow Data&lt;/h3&gt;
&lt;p&gt;Loads data from a base64-encoded Apache Arrow payload entered in the &lt;strong&gt;String Input&lt;/strong&gt; text area. Use this to test Arrow format rendering.&lt;/p&gt;
&lt;h3 id=&#34;table-static&#34;&gt;Table Static&lt;/h3&gt;
&lt;p&gt;Generates a static table with predefined columns: Time, Message, Description, and Value.&lt;/p&gt;
&lt;h2 id=&#34;visualization-test-scenarios&#34;&gt;Visualization test scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios generate data for testing specific visualization types.&lt;/p&gt;
&lt;h3 id=&#34;logs&#34;&gt;Logs&lt;/h3&gt;
&lt;p&gt;Generates simulated log data with random log levels, container IDs, and hostnames.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Lines&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of log lines to generate. Default: &lt;code&gt;10&lt;/code&gt;. Maximum: &lt;code&gt;10000&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Level&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Toggle to include a separate level column in the data instead of embedding it in messages.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;node-graph&#34;&gt;Node Graph&lt;/h3&gt;
&lt;p&gt;Generates data for the 
    &lt;a href=&#34;/docs/grafana/v13.0/panels-visualizations/visualizations/node-graph/&#34;&gt;Node Graph visualization&lt;/a&gt;.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Data type&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Type of graph data: &lt;code&gt;random&lt;/code&gt;, &lt;code&gt;response_small&lt;/code&gt;, &lt;code&gt;response_medium&lt;/code&gt;, &lt;code&gt;random edges&lt;/code&gt;, or &lt;code&gt;feature_showcase&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of nodes to generate. Available for &lt;code&gt;random&lt;/code&gt; and &lt;code&gt;random edges&lt;/code&gt; types.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Seed&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Seed value for reproducible random generation. Available for &lt;code&gt;random&lt;/code&gt; and &lt;code&gt;random edges&lt;/code&gt; types.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;flame-graph&#34;&gt;Flame Graph&lt;/h3&gt;
&lt;p&gt;Generates data for the 
    &lt;a href=&#34;/docs/grafana/v13.0/panels-visualizations/visualizations/flame-graph/&#34;&gt;Flame Graph visualization&lt;/a&gt;.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Diff profile&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Toggle to generate a differential flame graph comparing two profiles.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;trace&#34;&gt;Trace&lt;/h3&gt;
&lt;p&gt;Generates simulated distributed trace data.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Span count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of spans in the generated trace.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;annotations&#34;&gt;Annotations&lt;/h3&gt;
&lt;p&gt;Generates synthetic annotation data points. These annotations are created entirely in the browser and are useful for testing how panels display annotation markers and overlays. They don&amp;rsquo;t query an external source or persist data.&lt;/p&gt;
&lt;p&gt;For more information about annotations in Grafana, refer to 
    &lt;a href=&#34;/docs/grafana/v13.0/dashboards/build-dashboards/annotate-visualizations/&#34;&gt;Annotate visualizations&lt;/a&gt;.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Number of annotations to generate. Default: &lt;code&gt;10&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;exponential-heatmap-bucket-data&#34;&gt;Exponential heatmap bucket data&lt;/h3&gt;
&lt;p&gt;Generates heatmap data with exponentially distributed bucket boundaries (1, 2, 4, 8, 16, &amp;hellip;). Use this to test heatmap panels with exponential distributions.&lt;/p&gt;
&lt;h3 id=&#34;linear-heatmap-bucket-data&#34;&gt;Linear heatmap bucket data&lt;/h3&gt;
&lt;p&gt;Generates heatmap data with linearly distributed bucket boundaries (0, 10, 20, 30, &amp;hellip;). Use this to test heatmap panels with linear distributions.&lt;/p&gt;
&lt;h2 id=&#34;streaming-scenarios&#34;&gt;Streaming scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios produce real-time streaming data. Data updates continuously in the browser without requiring manual query execution.&lt;/p&gt;
&lt;h3 id=&#34;streaming-client&#34;&gt;Streaming Client&lt;/h3&gt;
&lt;p&gt;Generates streaming data directly from the browser client.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Type&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Stream type: &lt;code&gt;Signal&lt;/code&gt;, &lt;code&gt;Logs&lt;/code&gt;, &lt;code&gt;Fetch&lt;/code&gt;, &lt;code&gt;Traces&lt;/code&gt;, or &lt;code&gt;Watch&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Additional fields depend on the selected type:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Signal:&lt;/strong&gt; Speed (ms), Spread, Noise, Bands.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Logs, Traces, Watch:&lt;/strong&gt; Speed (ms) only.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Fetch:&lt;/strong&gt; URL of a remote CSV endpoint to stream incrementally.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;grafana-live&#34;&gt;Grafana Live&lt;/h3&gt;
&lt;p&gt;Connects to a Grafana Live channel that streams random data from the server.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Channel&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;The live channel to subscribe to. Options:&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Channel&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;random-2s-stream&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Random stream with points every 2s.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;random-flakey-stream&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Stream that returns data at random intervals.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;random-labeled-stream&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Value with moving labels.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;random-20Hz-stream&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Random stream with points at 20 Hz.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;data-retrieval-scenarios&#34;&gt;Data retrieval scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios fetch data from internal Grafana endpoints.&lt;/p&gt;
&lt;h3 id=&#34;grafana-api&#34;&gt;Grafana API&lt;/h3&gt;
&lt;p&gt;Fetches data from internal Grafana API endpoints and returns the result as a data frame. This scenario runs in the browser.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Endpoint&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;The API endpoint to query. Options:&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Endpoint&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Data Sources&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Lists configured data sources.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Search&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Returns dashboard search results.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Annotations&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Returns annotations.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;error-and-edge-case-testing-scenarios&#34;&gt;Error and edge-case testing scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios help test how Grafana handles errors, empty data, and slow responses.&lt;/p&gt;
&lt;h3 id=&#34;conditional-error&#34;&gt;Conditional Error&lt;/h3&gt;
&lt;p&gt;Produces an error or data depending on the &lt;strong&gt;String Input&lt;/strong&gt; and &lt;strong&gt;Error type&lt;/strong&gt; fields. When the &lt;strong&gt;String Input&lt;/strong&gt; field is empty, the scenario triggers the selected error type. When the field contains CSV values (default: &lt;code&gt;1,20,90,30,5,0&lt;/code&gt;), it returns time-series data like the CSV Metric Values scenario, regardless of the error type.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Error type&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Type of error to simulate: &lt;code&gt;Server panic&lt;/code&gt; (backend panic), &lt;code&gt;Frontend exception&lt;/code&gt; (uncaught error in the browser), or &lt;code&gt;Frontend observable&lt;/code&gt; (error emitted through the query observable).&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;To trigger an error, clear the &lt;strong&gt;String Input&lt;/strong&gt; field and select the error type you want to test.&lt;/p&gt;
&lt;h3 id=&#34;error-with-source&#34;&gt;Error with source&lt;/h3&gt;
&lt;p&gt;Returns an error with a configurable source classification.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Error source&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Source of the error: &lt;code&gt;Plugin&lt;/code&gt; (plugin error) or &lt;code&gt;Downstream&lt;/code&gt; (downstream service error).&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Use this to test how Grafana differentiates between plugin errors and downstream errors in alerting and error handling.&lt;/p&gt;
&lt;h3 id=&#34;no-data-points&#34;&gt;No Data Points&lt;/h3&gt;
&lt;p&gt;Returns an empty result with no data points. Use this to test how panels display when there&amp;rsquo;s no data.&lt;/p&gt;
&lt;h3 id=&#34;data-points-outside-range&#34;&gt;Data points Outside Range&lt;/h3&gt;
&lt;p&gt;Returns a single data point with a timestamp one hour before the query time range. Use this to test how panels handle data outside the visible range.&lt;/p&gt;
&lt;h3 id=&#34;slow-query&#34;&gt;Slow Query&lt;/h3&gt;
&lt;p&gt;Introduces a configurable delay before returning random walk data. Set the delay duration in the &lt;strong&gt;String Input&lt;/strong&gt; field using Go duration syntax (for example, &lt;code&gt;5s&lt;/code&gt;, &lt;code&gt;1m&lt;/code&gt;, &lt;code&gt;500ms&lt;/code&gt;). Default: &lt;code&gt;5s&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id=&#34;metadata-scenarios&#34;&gt;Metadata scenarios&lt;/h2&gt;
&lt;p&gt;These scenarios return metadata rather than time-series data.&lt;/p&gt;
&lt;h3 id=&#34;query-metadata&#34;&gt;Query Metadata&lt;/h3&gt;
&lt;p&gt;Returns a table with query metadata including the current user&amp;rsquo;s username. Use this to verify that query context information is available.&lt;/p&gt;
]]></content><description>&lt;h1 id="testdata-query-editor">TestData query editor&lt;/h1>
&lt;p>Instead of a traditional query language, the TestData data source uses &lt;strong>scenarios&lt;/strong> to generate simulated data. Each scenario produces a different type of data suited for testing specific visualizations, behaviors, or edge cases. TestData includes 30 scenarios covering time series, logs, traces, graphs, streaming, and error simulation.&lt;/p></description></item><item><title>TestData template variables</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/template-variables/</link><pubDate>Tue, 14 Apr 2026 14:59:56 +0000</pubDate><guid>https://grafana.com/docs/grafana/v13.0/datasources/testdata/template-variables/</guid><content><![CDATA[&lt;h1 id=&#34;testdata-template-variables&#34;&gt;TestData template variables&lt;/h1&gt;
&lt;p&gt;Use template variables with the TestData data source to test dynamic, reusable dashboards. TestData provides a hierarchical metric tree that you can query to populate variable drop-downs with simulated values.&lt;/p&gt;
&lt;p&gt;For an introduction to templating and template variables, refer to the 
    &lt;a href=&#34;/docs/grafana/v13.0/dashboards/variables/&#34;&gt;Templating&lt;/a&gt; and 
    &lt;a href=&#34;/docs/grafana/v13.0/dashboards/variables/add-template-variables/&#34;&gt;Add and manage variables&lt;/a&gt; documentation.&lt;/p&gt;
&lt;h2 id=&#34;supported-variable-types&#34;&gt;Supported variable types&lt;/h2&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Variable type&lt;/th&gt;
              &lt;th&gt;Supported&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;Query&lt;/td&gt;
              &lt;td&gt;Yes&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Custom&lt;/td&gt;
              &lt;td&gt;Yes&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Data source&lt;/td&gt;
              &lt;td&gt;Yes&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h2 id=&#34;create-a-query-variable&#34;&gt;Create a query variable&lt;/h2&gt;
&lt;p&gt;To create a query variable using TestData:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Navigate to &lt;strong&gt;Dashboard settings&lt;/strong&gt; &amp;gt; &lt;strong&gt;Variables&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Add variable&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Select &lt;strong&gt;Query&lt;/strong&gt; as the variable type.&lt;/li&gt;
&lt;li&gt;Select the &lt;strong&gt;TestData&lt;/strong&gt; data source.&lt;/li&gt;
&lt;li&gt;Enter your query in the &lt;strong&gt;Query&lt;/strong&gt; field.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;metric-tree-queries&#34;&gt;Metric tree queries&lt;/h2&gt;
&lt;p&gt;TestData generates a hierarchical metric tree with nodes named using letter combinations. The tree has 6 levels of depth, with each level containing 8 nodes labeled A through H. The query string navigates this tree using dot-separated path segments.&lt;/p&gt;
&lt;h3 id=&#34;query-syntax&#34;&gt;Query syntax&lt;/h3&gt;
&lt;p&gt;Use &lt;code&gt;*&lt;/code&gt; as a wildcard to return all children at a given level:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Query&lt;/th&gt;
              &lt;th&gt;Result&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns the top-level nodes: &lt;code&gt;A&lt;/code&gt;, &lt;code&gt;B&lt;/code&gt;, &lt;code&gt;C&lt;/code&gt;, &lt;code&gt;D&lt;/code&gt;, &lt;code&gt;E&lt;/code&gt;, &lt;code&gt;F&lt;/code&gt;, &lt;code&gt;G&lt;/code&gt;, &lt;code&gt;H&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;A.*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns children of node A: &lt;code&gt;AA&lt;/code&gt;, &lt;code&gt;AB&lt;/code&gt;, &lt;code&gt;AC&lt;/code&gt;, &lt;code&gt;AD&lt;/code&gt;, &lt;code&gt;AE&lt;/code&gt;, &lt;code&gt;AF&lt;/code&gt;, &lt;code&gt;AG&lt;/code&gt;, &lt;code&gt;AH&lt;/code&gt;.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;A.AA.*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns children of node AA: &lt;code&gt;AAA&lt;/code&gt;, &lt;code&gt;AAB&lt;/code&gt;, &lt;code&gt;AAC&lt;/code&gt;, etc.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;A.AB&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns children of the AB node: &lt;code&gt;ABA&lt;/code&gt;, &lt;code&gt;ABB&lt;/code&gt;, &lt;code&gt;ABC&lt;/code&gt;, etc.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Use glob patterns with curly braces to match multiple nodes:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Query&lt;/th&gt;
              &lt;th&gt;Result&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;{A,B}.*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns children of both A and B: &lt;code&gt;AA&lt;/code&gt;, &lt;code&gt;AB&lt;/code&gt;, &amp;hellip;, &lt;code&gt;BA&lt;/code&gt;, &lt;code&gt;BB&lt;/code&gt;, etc.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;A.{AA,AB}.*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns children of AA and AB: &lt;code&gt;AAA&lt;/code&gt;, &lt;code&gt;AAB&lt;/code&gt;, &amp;hellip;, &lt;code&gt;ABA&lt;/code&gt;, &lt;code&gt;ABB&lt;/code&gt;, etc.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Use &lt;code&gt;*&lt;/code&gt; after a prefix to match nodes that start with the given string:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Query&lt;/th&gt;
              &lt;th&gt;Result&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;A*&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Returns all top-level nodes starting with A (only &lt;code&gt;A&lt;/code&gt; at the top level).&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;value-queries&#34;&gt;Value queries&lt;/h3&gt;
&lt;p&gt;If your query string starts with &lt;code&gt;value&lt;/code&gt;, TestData returns the query string itself as the result. This is useful for creating variables with specific values for testing. For example, a query of &lt;code&gt;value_production&lt;/code&gt; returns &lt;code&gt;value_production&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id=&#34;example-create-a-region-variable&#34;&gt;Example: Create a region variable&lt;/h2&gt;
&lt;p&gt;This example walks through creating a query variable that populates a drop-down with simulated region values, then using it in a panel query.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Navigate to &lt;strong&gt;Dashboard settings&lt;/strong&gt; &amp;gt; &lt;strong&gt;Variables&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Add variable&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Set &lt;strong&gt;Type&lt;/strong&gt; to &lt;strong&gt;Query&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Select the &lt;strong&gt;TestData&lt;/strong&gt; data source.&lt;/li&gt;
&lt;li&gt;Enter &lt;code&gt;*&lt;/code&gt; in the &lt;strong&gt;Query&lt;/strong&gt; field. This populates the variable with the top-level nodes (A through H).&lt;/li&gt;
&lt;li&gt;Name the variable &lt;code&gt;region&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Apply&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;To use the variable in a panel:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Add a new panel and select the &lt;strong&gt;TestData&lt;/strong&gt; data source.&lt;/li&gt;
&lt;li&gt;Choose the &lt;strong&gt;Random Walk&lt;/strong&gt; scenario.&lt;/li&gt;
&lt;li&gt;In the &lt;strong&gt;Labels&lt;/strong&gt; field, enter &lt;code&gt;region=$region&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;The panel updates when you select a different value from the &lt;strong&gt;region&lt;/strong&gt; drop-down.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;example-chain-variables-for-cascading-drop-downs&#34;&gt;Example: Chain variables for cascading drop-downs&lt;/h2&gt;
&lt;p&gt;You can create dependent variables where one variable&amp;rsquo;s query references another, producing cascading drop-downs.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Create a variable named &lt;code&gt;region&lt;/code&gt; with the query &lt;code&gt;*&lt;/code&gt;. This returns the top-level nodes (A through H).&lt;/li&gt;
&lt;li&gt;Create a second variable named &lt;code&gt;host&lt;/code&gt; with the query &lt;code&gt;$region.*&lt;/code&gt;. When the user selects &lt;code&gt;A&lt;/code&gt; as the region, the host drop-down populates with &lt;code&gt;AA&lt;/code&gt;, &lt;code&gt;AB&lt;/code&gt;, &lt;code&gt;AC&lt;/code&gt;, etc.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Changing the region selection automatically refreshes the host drop-down.&lt;/p&gt;
&lt;h2 id=&#34;use-variables-in-queries&#34;&gt;Use variables in queries&lt;/h2&gt;
&lt;p&gt;TestData interpolates template variables in the following query fields:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Labels&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Alias&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Scenario&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;String Input&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;CSV Content&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Raw Frame Content&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Use the standard Grafana variable syntax (&lt;code&gt;$varname&lt;/code&gt; or &lt;code&gt;${varname}&lt;/code&gt;) in any of these fields to insert variable values.&lt;/p&gt;
&lt;h3 id=&#34;example&#34;&gt;Example&lt;/h3&gt;
&lt;p&gt;With a variable named &lt;code&gt;env&lt;/code&gt; set to &lt;code&gt;production&lt;/code&gt;, entering &lt;code&gt;env=$env&lt;/code&gt; in the &lt;strong&gt;Labels&lt;/strong&gt; field produces a series labeled &lt;code&gt;env=production&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id=&#34;limitations&#34;&gt;Limitations&lt;/h2&gt;
&lt;p&gt;TestData doesn&amp;rsquo;t support the 
    &lt;a href=&#34;/docs/grafana/v13.0/dashboards/variables/add-template-variables/#add-ad-hoc-filters&#34;&gt;filters variable&lt;/a&gt;. Filters require the data source to implement tag key and value lookups, which TestData doesn&amp;rsquo;t provide.&lt;/p&gt;
]]></content><description>&lt;h1 id="testdata-template-variables">TestData template variables&lt;/h1>
&lt;p>Use template variables with the TestData data source to test dynamic, reusable dashboards. TestData provides a hierarchical metric tree that you can query to populate variable drop-downs with simulated values.&lt;/p></description></item><item><title>TestData alerting</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/alerting/</link><pubDate>Tue, 14 Apr 2026 14:59:56 +0000</pubDate><guid>https://grafana.com/docs/grafana/v13.0/datasources/testdata/alerting/</guid><content><![CDATA[&lt;h1 id=&#34;testdata-alerting&#34;&gt;TestData alerting&lt;/h1&gt;
&lt;p&gt;The TestData data source supports 
    &lt;a href=&#34;/docs/grafana/v13.0/alerting/&#34;&gt;Grafana Alerting&lt;/a&gt;. You can use it to prototype alert rules, test threshold conditions, and verify notification pipelines without connecting to an external data source.&lt;/p&gt;
&lt;h2 id=&#34;before-you-begin&#34;&gt;Before you begin&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/configure/&#34;&gt;Configure the TestData data source&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Familiarize yourself with 
    &lt;a href=&#34;/docs/grafana/v13.0/alerting/fundamentals/alert-rules/&#34;&gt;alert rules&lt;/a&gt; and how to 
    &lt;a href=&#34;/docs/grafana/v13.0/alerting/alerting-rules/create-grafana-managed-rule/&#34;&gt;create a Grafana-managed alert rule&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;choose-a-scenario-for-alerting&#34;&gt;Choose a scenario for alerting&lt;/h2&gt;
&lt;p&gt;TestData scenarios that return time-series data work with alert rule conditions. Choose a scenario based on the behavior you want to test.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Scenario&lt;/th&gt;
              &lt;th&gt;Alerting use case&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Predictable Pulse&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Deterministic on/off pattern. Produces repeatable alert firing and resolving on a fixed cycle.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Random Walk&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Non-deterministic time series. Useful for quick prototyping and load testing alert evaluation.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;CSV Metric Values&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Controlled, fixed values. Test exact threshold boundaries.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Predictable CSV Wave&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Custom repeating waveforms. Test complex threshold patterns with precise control.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Random Walk (with error)&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Returns both data and an error. Test how alerts handle partial failures.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Error with source&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Returns a plugin or downstream error. Test alert evaluation error handling.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;No Data Points&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Returns empty results. Test no-data alert conditions.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Slow Query&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;Introduces a configurable delay. Test alert evaluation timeouts.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Scenarios that produce logs, traces, or streaming data aren&amp;rsquo;t suitable for threshold-based alert conditions.&lt;/p&gt;
&lt;h2 id=&#34;create-an-alert-rule&#34;&gt;Create an alert rule&lt;/h2&gt;
&lt;p&gt;To create an alert rule using TestData:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Navigate to &lt;strong&gt;Alerting&lt;/strong&gt; &amp;gt; &lt;strong&gt;Alert rules&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;New alert rule&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Enter a name for the rule.&lt;/li&gt;
&lt;li&gt;Select the &lt;strong&gt;TestData&lt;/strong&gt; data source.&lt;/li&gt;
&lt;li&gt;Choose a scenario from the &lt;strong&gt;Scenario&lt;/strong&gt; drop-down (for example, &lt;strong&gt;Predictable Pulse&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;Configure the scenario options.&lt;/li&gt;
&lt;li&gt;Add a &lt;strong&gt;Reduce&lt;/strong&gt; expression to aggregate the series (for example, &lt;strong&gt;Last&lt;/strong&gt; value).&lt;/li&gt;
&lt;li&gt;Add a &lt;strong&gt;Threshold&lt;/strong&gt; expression to define the condition (for example, &lt;strong&gt;Is above&lt;/strong&gt; &lt;code&gt;0.5&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Set the evaluation interval and pending period.&lt;/li&gt;
&lt;li&gt;Configure notifications and labels.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Save rule&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;For detailed instructions, refer to 
    &lt;a href=&#34;/docs/grafana/v13.0/alerting/alerting-rules/create-grafana-managed-rule/&#34;&gt;Create a Grafana-managed alert rule&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;example-predictable-pulse-alert&#34;&gt;Example: Predictable Pulse alert&lt;/h2&gt;
&lt;p&gt;The Predictable Pulse scenario produces a repeating on/off wave that&amp;rsquo;s ideal for testing alert rules because the firing pattern is deterministic and reproducible.&lt;/p&gt;
&lt;p&gt;To create a Predictable Pulse alert:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Select the &lt;strong&gt;Predictable Pulse&lt;/strong&gt; scenario.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Configure the pulse options:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Field&lt;/th&gt;
              &lt;th&gt;Value&lt;/th&gt;
              &lt;th&gt;Effect&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Step&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;60&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;One data point every 60 seconds.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;On Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;3&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Three consecutive points at the &amp;ldquo;on&amp;rdquo; value.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Off Count&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;6&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Six consecutive points at the &amp;ldquo;off&amp;rdquo; value.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;On Value&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;1&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Value during the &amp;ldquo;on&amp;rdquo; phase.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;strong&gt;Off Value&lt;/strong&gt;&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;0&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Value during the &amp;ldquo;off&amp;rdquo; phase.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add a &lt;strong&gt;Reduce&lt;/strong&gt; expression with function &lt;strong&gt;Last&lt;/strong&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add a &lt;strong&gt;Threshold&lt;/strong&gt; expression: &lt;strong&gt;Is above&lt;/strong&gt; &lt;code&gt;0.5&lt;/code&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;With this configuration, the alert fires for 3 minutes (3 x 60s on-points) and then resolves for 6 minutes (6 x 60s off-points), repeating indefinitely. Adjust the step, on count, and off count to control the timing.&lt;/p&gt;
&lt;h2 id=&#34;example-csv-metric-values-threshold-alert&#34;&gt;Example: CSV Metric Values threshold alert&lt;/h2&gt;
&lt;p&gt;The CSV Metric Values scenario lets you define an exact sequence of data points, making it useful for testing precise threshold boundaries.&lt;/p&gt;
&lt;p&gt;To create a threshold alert with fixed values:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Select the &lt;strong&gt;CSV Metric Values&lt;/strong&gt; scenario.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Enter a comma-separated list of values in the &lt;strong&gt;String Input&lt;/strong&gt; field. For example:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;10,45,70,95,50,20&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add a &lt;strong&gt;Reduce&lt;/strong&gt; expression with function &lt;strong&gt;Last&lt;/strong&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add a &lt;strong&gt;Threshold&lt;/strong&gt; expression: &lt;strong&gt;Is above&lt;/strong&gt; &lt;code&gt;80&lt;/code&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;With this input, the series cycles through the values &lt;code&gt;10, 45, 70, 95, 50, 20&lt;/code&gt;. The alert fires when the reduced value exceeds &lt;code&gt;80&lt;/code&gt; (the &lt;code&gt;95&lt;/code&gt; data point) and resolves when it drops back below the threshold.&lt;/p&gt;
&lt;p&gt;This approach is helpful for validating that a threshold condition triggers at the exact boundary you expect.&lt;/p&gt;
&lt;h2 id=&#34;test-error-and-no-data-conditions&#34;&gt;Test error and no-data conditions&lt;/h2&gt;
&lt;p&gt;TestData includes scenarios designed for testing how alerts respond to failures. Use these to verify that your alert rules handle edge cases correctly before connecting to production data sources.&lt;/p&gt;
&lt;h3 id=&#34;no-data&#34;&gt;No data&lt;/h3&gt;
&lt;p&gt;Select the &lt;strong&gt;No Data Points&lt;/strong&gt; scenario. The backend returns an empty result, which triggers the alert rule&amp;rsquo;s &lt;strong&gt;no data&lt;/strong&gt; state. Use this to verify that your rule is configured to alert, keep the last state, or resolve when no data is received. Configure this behavior in the alert rule&amp;rsquo;s &lt;strong&gt;No data and error handling&lt;/strong&gt; section.&lt;/p&gt;
&lt;h3 id=&#34;errors&#34;&gt;Errors&lt;/h3&gt;
&lt;p&gt;Select &lt;strong&gt;Error with source&lt;/strong&gt; and choose the error type:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Plugin&lt;/strong&gt; — simulates a failure in the plugin itself. The alert enters an error state.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Downstream&lt;/strong&gt; — simulates a failure in the data source or network. The alert enters an error state with a downstream classification.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can also use &lt;strong&gt;Random Walk (with error)&lt;/strong&gt;, which returns valid data alongside an error, to test how the alerting engine handles partial failures.&lt;/p&gt;
&lt;h3 id=&#34;timeouts&#34;&gt;Timeouts&lt;/h3&gt;
&lt;p&gt;Select &lt;strong&gt;Slow Query&lt;/strong&gt; and set the &lt;strong&gt;String Input&lt;/strong&gt; field to a duration longer than your evaluation interval (for example, &lt;code&gt;30s&lt;/code&gt; for a rule evaluated every &lt;code&gt;10s&lt;/code&gt;). The default delay is &lt;code&gt;5s&lt;/code&gt;. Use this to verify timeout behavior and confirm that alerts transition to the expected state when queries take too long.&lt;/p&gt;
&lt;h2 id=&#34;limitations&#34;&gt;Limitations&lt;/h2&gt;
&lt;p&gt;When using TestData with Grafana Alerting, be aware of the following limitations.&lt;/p&gt;
&lt;h3 id=&#34;template-variables-arent-supported-in-alert-queries&#34;&gt;Template variables aren&amp;rsquo;t supported in alert queries&lt;/h3&gt;
&lt;p&gt;Grafana evaluates alert rules on the backend without dashboard context. Template variables like &lt;code&gt;$varname&lt;/code&gt; aren&amp;rsquo;t resolved during alert evaluation. Use fixed values in the scenario options instead.&lt;/p&gt;
&lt;h3 id=&#34;only-time-series-scenarios-work-with-alert-conditions&#34;&gt;Only time-series scenarios work with alert conditions&lt;/h3&gt;
&lt;p&gt;Alert conditions require numeric time-series data. Scenarios that produce logs (Logs), traces (Trace), graphs (Node Graph, Flame Graph), annotations (Annotations), or tables (Table Static) can&amp;rsquo;t be used as alert conditions.&lt;/p&gt;
&lt;h3 id=&#34;streaming-scenarios-arent-evaluated-by-the-alerting-engine&#34;&gt;Streaming scenarios aren&amp;rsquo;t evaluated by the alerting engine&lt;/h3&gt;
&lt;p&gt;The alerting engine evaluates queries at fixed intervals and doesn&amp;rsquo;t consume streaming data. Avoid using Streaming Client, Grafana Live, or Simulation with streaming enabled for alert rules.&lt;/p&gt;
]]></content><description>&lt;h1 id="testdata-alerting">TestData alerting&lt;/h1>
&lt;p>The TestData data source supports
&lt;a href="/docs/grafana/v13.0/alerting/">Grafana Alerting&lt;/a>. You can use it to prototype alert rules, test threshold conditions, and verify notification pipelines without connecting to an external data source.&lt;/p></description></item><item><title>Troubleshoot TestData data source issues</title><link>https://grafana.com/docs/grafana/v13.0/datasources/testdata/troubleshooting/</link><pubDate>Tue, 14 Apr 2026 14:59:56 +0000</pubDate><guid>https://grafana.com/docs/grafana/v13.0/datasources/testdata/troubleshooting/</guid><content><![CDATA[&lt;h1 id=&#34;troubleshoot-testdata-data-source-issues&#34;&gt;Troubleshoot TestData data source issues&lt;/h1&gt;
&lt;p&gt;This document provides solutions to common issues you may encounter when using the TestData data source. TestData is a built-in data source with no external dependencies, so most issues relate to scenario configuration or data formatting.&lt;/p&gt;
&lt;h2 id=&#34;query-errors&#34;&gt;Query errors&lt;/h2&gt;
&lt;p&gt;These errors occur when running TestData scenarios.&lt;/p&gt;
&lt;h3 id=&#34;no-data-or-empty-panels&#34;&gt;&amp;ldquo;No data&amp;rdquo; or empty panels&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Panel displays &amp;ldquo;No data&amp;rdquo; message.&lt;/li&gt;
&lt;li&gt;Query executes without error but returns nothing.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Possible causes and solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Cause&lt;/th&gt;
              &lt;th&gt;Solution&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;No Data Points scenario selected&lt;/td&gt;
              &lt;td&gt;The No Data Points scenario returns empty results by design. Select a different scenario such as Random Walk.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Data Points Outside Range selected&lt;/td&gt;
              &lt;td&gt;This scenario returns a data point one hour before the query time range. Expand the time range or select a different scenario.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Empty String Input for CSV scenarios&lt;/td&gt;
              &lt;td&gt;CSV Metric Values and CSV Content require input data. Add comma-separated values or CSV content.&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Time range doesn&amp;rsquo;t contain data&lt;/td&gt;
              &lt;td&gt;Some scenarios generate data relative to the query time range. Expand the dashboard time range.&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;h3 id=&#34;unexpected-error-from-conditional-error&#34;&gt;Unexpected error from Conditional Error&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Query returns a server error or panic message.&lt;/li&gt;
&lt;li&gt;Error appears immediately when running the query.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The Conditional Error scenario triggers a server panic when the &lt;strong&gt;String Input&lt;/strong&gt; field is empty. This is the intended behavior for error testing.&lt;/li&gt;
&lt;li&gt;To return data instead of an error, populate the &lt;strong&gt;String Input&lt;/strong&gt; field with comma-separated values (for example, &lt;code&gt;1,20,90,30,5,0&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;To change the error type, use the &lt;strong&gt;Error type&lt;/strong&gt; drop-down to select between Server panic, Frontend exception, and Frontend observable.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;error-with-source-returns-an-error&#34;&gt;Error with source returns an error&lt;/h3&gt;
&lt;p&gt;The Error with source scenario intentionally returns errors for testing how Grafana handles different error sources. This isn&amp;rsquo;t a misconfiguration.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Plugin&lt;/strong&gt; error source simulates an error originating from the plugin itself.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Downstream&lt;/strong&gt; error source simulates an error from a downstream service.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Use this scenario to test alerting rules, error displays, and error handling in custom panels.&lt;/p&gt;
&lt;h3 id=&#34;slow-query-appears-stuck&#34;&gt;Slow Query appears stuck&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Query runs for an extended period.&lt;/li&gt;
&lt;li&gt;Panel shows a loading spinner indefinitely.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Check the &lt;strong&gt;String Input&lt;/strong&gt; field, which controls the delay duration. The default is &lt;code&gt;5s&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Reduce the value to a shorter duration (for example, &lt;code&gt;1s&lt;/code&gt; or &lt;code&gt;500ms&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;The field accepts Go duration syntax: &lt;code&gt;5s&lt;/code&gt; (seconds), &lt;code&gt;1m&lt;/code&gt; (minutes), &lt;code&gt;500ms&lt;/code&gt; (milliseconds).&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;wrong-data-type-for-the-visualization&#34;&gt;Wrong data type for the visualization&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Panel shows &amp;ldquo;Data does not have a time field&amp;rdquo; or similar type mismatch errors.&lt;/li&gt;
&lt;li&gt;Visualization renders but looks wrong (for example, a table when you expected a graph).&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Match the scenario to the visualization type. For example, use the Logs scenario with the Logs panel, Node Graph with the Node Graph panel, and Trace with the Traces panel.&lt;/li&gt;
&lt;li&gt;Time-series panels require scenarios that produce time-series data (Random Walk, Predictable Pulse, CSV Metric Values, Predictable CSV Wave).&lt;/li&gt;
&lt;li&gt;For table panels, use Table Static, Random Walk Table, or CSV File.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;predictable-pulse-pattern-doesnt-match-expectations&#34;&gt;Predictable Pulse pattern doesn&amp;rsquo;t match expectations&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The on/off pattern doesn&amp;rsquo;t align with expected times.&lt;/li&gt;
&lt;li&gt;Values appear at unexpected intervals.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Predictable Pulse aligns timestamps to the step interval based on absolute time from the epoch, not from the start of the time range. This means the pattern starts at the same point regardless of when you load the dashboard.&lt;/li&gt;
&lt;li&gt;Verify the cycle duration matches your intent: the full cycle is &lt;code&gt;Step * (On Count &#43; Off Count)&lt;/code&gt; seconds.&lt;/li&gt;
&lt;li&gt;Check that &lt;strong&gt;On Value&lt;/strong&gt; and &lt;strong&gt;Off Value&lt;/strong&gt; are set correctly. The defaults are &lt;code&gt;2&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;, not &lt;code&gt;1&lt;/code&gt; and &lt;code&gt;0&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;csv-and-data-input-errors&#34;&gt;CSV and data input errors&lt;/h2&gt;
&lt;p&gt;These errors occur with scenarios that accept user-provided data.&lt;/p&gt;
&lt;h3 id=&#34;csv-content-or-csv-metric-values-return-unexpected-results&#34;&gt;CSV Content or CSV Metric Values return unexpected results&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Data doesn&amp;rsquo;t match expectations.&lt;/li&gt;
&lt;li&gt;Fewer data points than expected.&lt;/li&gt;
&lt;li&gt;Parsing errors.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Verify CSV formatting: headers in the first row, commas as delimiters, numeric values unquoted.&lt;/li&gt;
&lt;li&gt;For CSV Metric Values, enter only comma-separated numbers in the &lt;strong&gt;String Input&lt;/strong&gt; field (for example, &lt;code&gt;1,20,90,30,5,0&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;The special values &lt;code&gt;null&lt;/code&gt; and &lt;code&gt;nan&lt;/code&gt; are supported in Predictable CSV Wave values. Use &lt;code&gt;null&lt;/code&gt; for missing data points and &lt;code&gt;nan&lt;/code&gt; for Not-a-Number values.&lt;/li&gt;
&lt;li&gt;Check for trailing commas or extra whitespace in your input.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;raw-frames-json-parse-errors&#34;&gt;Raw Frames JSON parse errors&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Error message about invalid JSON.&lt;/li&gt;
&lt;li&gt;Panel fails to render.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Validate that the JSON matches the Grafana data frame format.&lt;/li&gt;
&lt;li&gt;Use the paste helpers in the editor to import data from panel JSON or raw query results.&lt;/li&gt;
&lt;li&gt;Verify that field types are consistent within each field array.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;streaming-errors&#34;&gt;Streaming errors&lt;/h2&gt;
&lt;p&gt;These errors occur with the Streaming Client and Grafana Live scenarios.&lt;/p&gt;
&lt;h3 id=&#34;streaming-client-doesnt-update&#34;&gt;Streaming Client doesn&amp;rsquo;t update&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Panel shows initial data but doesn&amp;rsquo;t update.&lt;/li&gt;
&lt;li&gt;No new data points appear over time.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Verify the &lt;strong&gt;Speed&lt;/strong&gt; field is set to a reasonable value (in milliseconds). Lower values produce faster updates.&lt;/li&gt;
&lt;li&gt;For the &lt;strong&gt;Fetch&lt;/strong&gt; type, verify the URL is accessible from the browser.&lt;/li&gt;
&lt;li&gt;Check the browser console for WebSocket or network errors.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;grafana-live-channel-shows-no-data&#34;&gt;Grafana Live channel shows no data&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Panel remains empty after selecting a channel.&lt;/li&gt;
&lt;li&gt;No streaming data appears.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Confirm the selected channel matches one of the available options: &lt;code&gt;random-2s-stream&lt;/code&gt;, &lt;code&gt;random-flakey-stream&lt;/code&gt;, &lt;code&gt;random-labeled-stream&lt;/code&gt;, or &lt;code&gt;random-20Hz-stream&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Verify that Grafana Live is enabled in your Grafana instance.&lt;/li&gt;
&lt;li&gt;Check the Grafana server logs for Live connection errors.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;template-variable-errors&#34;&gt;Template variable errors&lt;/h2&gt;
&lt;p&gt;These errors occur when using TestData with 
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/template-variables/&#34;&gt;dashboard template variables&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id=&#34;variable-drop-down-is-empty&#34;&gt;Variable drop-down is empty&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Variable drop-down shows no options.&lt;/li&gt;
&lt;li&gt;Preview in the variable editor returns zero values.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Verify the query string navigates valid nodes in the metric tree. Use &lt;code&gt;*&lt;/code&gt; to return all top-level nodes.&lt;/li&gt;
&lt;li&gt;Check that dot-separated path segments match the tree structure (for example, &lt;code&gt;A.*&lt;/code&gt; returns children of node A). An invalid path like &lt;code&gt;Z.*&lt;/code&gt; returns nothing because &lt;code&gt;Z&lt;/code&gt; doesn&amp;rsquo;t exist in the tree.&lt;/li&gt;
&lt;li&gt;Verify the TestData data source is selected in the variable editor.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Run query&lt;/strong&gt; in the variable editor preview to test.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;chained-variable-doesnt-update&#34;&gt;Chained variable doesn&amp;rsquo;t update&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;A dependent variable (for example, &lt;code&gt;$region.*&lt;/code&gt;) doesn&amp;rsquo;t refresh when the parent variable changes.&lt;/li&gt;
&lt;li&gt;The drop-down shows stale values from a previous selection.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Set the dependent variable&amp;rsquo;s &lt;strong&gt;Refresh&lt;/strong&gt; option to &lt;strong&gt;On dashboard load&lt;/strong&gt; or &lt;strong&gt;On time range change&lt;/strong&gt; in the variable editor.&lt;/li&gt;
&lt;li&gt;Verify the query uses the correct parent variable syntax (for example, &lt;code&gt;$region.*&lt;/code&gt; not &lt;code&gt;region.*&lt;/code&gt;).&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;variable-value-not-interpolated-in-queries&#34;&gt;Variable value not interpolated in queries&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Panel shows the literal string &lt;code&gt;$varname&lt;/code&gt; instead of the variable value.&lt;/li&gt;
&lt;li&gt;Labels or data don&amp;rsquo;t change when the variable selection changes.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Verify you&amp;rsquo;re using the correct variable syntax: &lt;code&gt;$varname&lt;/code&gt; or &lt;code&gt;${varname}&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;TestData interpolates variables in these fields only: &lt;strong&gt;Labels&lt;/strong&gt;, &lt;strong&gt;Alias&lt;/strong&gt;, &lt;strong&gt;Scenario&lt;/strong&gt;, &lt;strong&gt;String Input&lt;/strong&gt;, &lt;strong&gt;CSV Content&lt;/strong&gt;, and &lt;strong&gt;Raw Frame Content&lt;/strong&gt;. Other fields don&amp;rsquo;t support variable substitution.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;alerting-errors&#34;&gt;Alerting errors&lt;/h2&gt;
&lt;p&gt;These errors occur when using TestData with 
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/alerting/&#34;&gt;Grafana Alerting&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id=&#34;alert-rule-shows-no-data-unexpectedly&#34;&gt;Alert rule shows &amp;ldquo;no data&amp;rdquo; unexpectedly&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Alert rule status shows &lt;strong&gt;No Data&lt;/strong&gt; even though the scenario works in a panel.&lt;/li&gt;
&lt;li&gt;Alert never transitions to firing or normal.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Verify you&amp;rsquo;re using a backend-evaluated scenario. Browser-only scenarios (Streaming Client, Grafana Live, Grafana API, Steps, No Data Points) return empty results when evaluated by the alerting engine. Use a backend scenario like Random Walk or Predictable Pulse instead.&lt;/li&gt;
&lt;li&gt;Confirm the scenario is returning time-series data. Scenarios that produce logs (Logs), traces (Trace), graphs (Node Graph, Flame Graph), or tables (Table Static) can&amp;rsquo;t be used as alert conditions.&lt;/li&gt;
&lt;li&gt;Check that the &lt;strong&gt;String Input&lt;/strong&gt; field isn&amp;rsquo;t empty for scenarios that require it (for example, CSV Metric Values).&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;alert-rule-never-fires&#34;&gt;Alert rule never fires&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Alert rule stays in &lt;strong&gt;Normal&lt;/strong&gt; state.&lt;/li&gt;
&lt;li&gt;Data is visible in the panel but the alert condition is never met.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;If using Random Walk, the values are non-deterministic and may not exceed your threshold. Use Predictable Pulse or CSV Metric Values with values that reliably cross the threshold.&lt;/li&gt;
&lt;li&gt;Verify the &lt;strong&gt;Reduce&lt;/strong&gt; expression is aggregating correctly. For example, &lt;strong&gt;Last&lt;/strong&gt; returns the most recent value, while &lt;strong&gt;Mean&lt;/strong&gt; averages the series.&lt;/li&gt;
&lt;li&gt;Check the &lt;strong&gt;Threshold&lt;/strong&gt; expression. Click &lt;strong&gt;Preview&lt;/strong&gt; in the alert rule editor to see the evaluated value.&lt;/li&gt;
&lt;li&gt;Ensure the evaluation interval is long enough for the scenario to produce data points. A Predictable Pulse with Step=60 needs at least a 60-second evaluation window.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;template-variables-dont-resolve-in-alert-rules&#34;&gt;Template variables don&amp;rsquo;t resolve in alert rules&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Alert rule error mentions unresolved variables.&lt;/li&gt;
&lt;li&gt;Alert query uses &lt;code&gt;$varname&lt;/code&gt; syntax but the variable isn&amp;rsquo;t replaced.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Grafana evaluates alert rules on the backend without dashboard context. Template variables like &lt;code&gt;$varname&lt;/code&gt; aren&amp;rsquo;t resolved during alert evaluation. Replace variable references with fixed values in the scenario options.&lt;/p&gt;
&lt;p&gt;For more information, refer to the 
    &lt;a href=&#34;/docs/grafana/v13.0/datasources/testdata/alerting/#template-variables-arent-supported-in-alert-queries&#34;&gt;alerting limitations&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id=&#34;alert-evaluation-timeout&#34;&gt;Alert evaluation timeout&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Symptoms:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Alert rule transitions to &lt;strong&gt;Error&lt;/strong&gt; state.&lt;/li&gt;
&lt;li&gt;Logs show a timeout during query evaluation.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Solutions:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;If you&amp;rsquo;re using the Slow Query scenario, reduce the delay in the &lt;strong&gt;String Input&lt;/strong&gt; field to a value shorter than the evaluation interval.&lt;/li&gt;
&lt;li&gt;For other scenarios, verify that the query isn&amp;rsquo;t producing an excessive number of data points. Reduce the time range or increase the step interval.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;enable-debug-logging&#34;&gt;Enable debug logging&lt;/h2&gt;
&lt;p&gt;To capture detailed error information for troubleshooting:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Set the Grafana log level to &lt;code&gt;debug&lt;/code&gt; in the configuration file:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;ini&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-ini&#34;&gt;[log]
level = debug&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Review logs in &lt;code&gt;/var/log/grafana/grafana.log&lt;/code&gt; (or your configured log location).&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Look for entries containing &lt;code&gt;testdata&lt;/code&gt; or &lt;code&gt;testdatasource&lt;/code&gt; for scenario-specific details.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Reset the log level to &lt;code&gt;info&lt;/code&gt; after troubleshooting to avoid excessive log volume.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;get-additional-help&#34;&gt;Get additional help&lt;/h2&gt;
&lt;p&gt;If you&amp;rsquo;ve tried the solutions in this document and still encounter issues:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Check the &lt;a href=&#34;https://community.grafana.com/&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Grafana community forums&lt;/a&gt; for similar issues.&lt;/li&gt;
&lt;li&gt;Review &lt;a href=&#34;https://github.com/grafana/grafana/issues&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Grafana GitHub issues&lt;/a&gt; for known bugs.&lt;/li&gt;
&lt;li&gt;When reporting issues, include:
&lt;ul&gt;
&lt;li&gt;Grafana version&lt;/li&gt;
&lt;li&gt;Selected scenario and its configuration&lt;/li&gt;
&lt;li&gt;Error messages (redact sensitive information)&lt;/li&gt;
&lt;li&gt;Steps to reproduce&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
]]></content><description>&lt;h1 id="troubleshoot-testdata-data-source-issues">Troubleshoot TestData data source issues&lt;/h1>
&lt;p>This document provides solutions to common issues you may encounter when using the TestData data source. TestData is a built-in data source with no external dependencies, so most issues relate to scenario configuration or data formatting.&lt;/p></description></item></channel></rss>