All Apps and Add-ons

how to add a global variable to a dashboard

RickGenesis
Explorer

I have a standard dashboard that I want to reuse 20 - 50 times for different applications (there will be some added customization per application). The search's/macros are standardized and I pass in the name of the application as a parameter. I want to be able to set a variable (application name) that these searches etc will then get passed and display the required charts/tables. This is to simplify the creation of the dashboards for each application. We can just copy the base dashboard, edit the global variable, add a couple of application specific charts/tables to the bottom of the dashboard and Bobs your auntie. I could use a drop-down and hide it but this seems a little inelegant, any other options?
FYI I'm using advanced XML and Sideview.

1 Solution

sideview
SplunkTrust
SplunkTrust

Sounds like a job for the ValueSetter module. Put one of these up at the top of the view:

<module name="ValueSetter">
  <param name="name">application</param>
  <param name="value">AcmeWidgetMonitor</param>

and Bob is thus your auntie.

As it happens the latest release (2.4.8) has among its improvements a new documentation and examples page for the ValueSetter module. Check it out. Most of the times ValueSetter comes in handy aren't quite this simple, but these are the breaks.

http://sideviewapps.com/apps/sideview-utils

View solution in original post

0 Karma

sideview
SplunkTrust
SplunkTrust

Sounds like a job for the ValueSetter module. Put one of these up at the top of the view:

<module name="ValueSetter">
  <param name="name">application</param>
  <param name="value">AcmeWidgetMonitor</param>

and Bob is thus your auntie.

As it happens the latest release (2.4.8) has among its improvements a new documentation and examples page for the ValueSetter module. Check it out. Most of the times ValueSetter comes in handy aren't quite this simple, but these are the breaks.

http://sideviewapps.com/apps/sideview-utils

0 Karma

RickGenesis
Explorer

perfect, Bobetta's loving her new outfit

0 Karma

pal4life
Path Finder

I am getting the validation error for this one in the dashboard source as module not allowed here. Where exactly should this be placed?

Thanks.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...