Dashboards & Visualizations

Tag Cloud with Tokens

nyp_kwyc
Explorer
 <html>
                <div id="tagcloud-search"
                     class="splunk-manager splunk-searchmanager "
                     data-require="splunkjs/mvc/searchmanager"
                     data-options='{
                            "app": "simple_xml_examples",
                            "preview": true,
                            "search": "index=_internal source=*metrics.log group=pipeline host$host$ | stats max(cpu_seconds) as cpu_seconds sum(executes) as executes sum(cumulative_hits) as cumulative_hits by processor",
                            "earliest_time": { "type": "token_safe", "value": "$$earliest$$" },
                            "latest_time": { "type": "token_safe", "value": "$$latest$$" }
                        }'>
                </div>

                <div id="tagcloud"
                     class="splunk-view"
                     data-require="app/simple_xml_examples/components/tagcloud/tagcloud"
                     data-options='{
                            "minFontSize": 15,
                            "maxFontSize": 95,
                            "managerid": "tagcloud-search",
                            "valueField": { "type": "token_safe", "value": "$$metric$$" },
                            "labelField": "processor"
                         }'>
                </div>
            </html>

Is it possible to assign token on the search query for $host$

0 Karma

NOUMSSI
Builder

Hi,

It's possible to assign token on the search query for $host$. Replace your query by this:

"search": "index=_internal source=*metrics.log group=pipeline host=$host$ | stats max(cpu_seconds) as cpu_seconds sum(executes) as executes sum(cumulative_hits) as cumulative_hits by processor"

0 Karma
Get Updates on the Splunk Community!

Index This | I’m short for "configuration file.” What am I?

May 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with a Special ...

New Articles from Academic Learning Partners, Help Expand Lantern’s Use Case Library, ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Your Guide to SPL2 at .conf24!

So, you’re headed to .conf24? You’re in for a good time. Las Vegas weather is just *chef’s kiss* beautiful in ...