Splunk IT Service Intelligence

How to customize colors on a XML dashboard based on status indicators?


I am trying to create a dashboard that shows a red box around a failed or down state, and a green box around passed or up state. Currently, I am getting the dashboard, but the boxes will only show as black.

Could someone please show me what I am doing wrong?

  <label>Website State</label>
          <query>index="amazon-aws" sourcetype="aws:cloudwatchlogs" state_new=* AND site_location=*
                |eval state_new=if(state_new=="PASSED","up","down")
                |eval range=if(state_new=="PASSED","low","severe")
                |stats latest(state_new) AS state_new BY site_location</query>
        <option name="colorBy">value</option>
        <option name="colorMode">block</option>
        <option name="drilldown">none</option>
        <option name="field">range</option>
        <option name="numberPrecision">0</option>
        <option name="rangeColors">["0x53a051", "0x0877a6", "0xf8be34", "0xf1813f", "0xdc4e41"]</option>
        <option name="rangeValues">[0,30,70,100]</option>
        <option name="showSparkline">1</option>
        <option name="showTrendIndicator">1</option>
        <option name="trellis.enabled">1</option>
        <option name="trellis.scales.shared">1</option>
        <option name="trellis.size">small</option>
        <option name="trellis.splitBy">site_location</option>
        <option name="unitPosition">after</option>
        <option name="useColors">1</option>
        <option name="useThousandSeparators">1</option>

alt text

Labels (3)
0 Karma
Get Updates on the Splunk Community!

How I Instrumented a Rust Application Without Knowing Rust

As a technical writer, I often have to edit or create code snippets for Splunk's distributions of ...

Splunk Community Platform Survey

Hey Splunk Community, Starting today, the community platform may prompt you to participate in a survey. The ...

Observability Highlights | November 2022 Newsletter

 November 2022Observability CloudEnd Of Support Extension for SignalFx Smart AgentSplunk is extending the End ...