Dashboards & Visualizations

How do you set a view in html dashboards to refresh periodically?

sillingworth
Path Finder

I've written a very simple xml dashboard with one single view on it, updating every minute. I've converted it to an html dashboard. It no longer updates every minute.

How do you set views in html dashboards to refresh periodically?

Tags (3)
0 Karma

dineshraj9
Builder

Check the visualization elements created in your HTML view and set the refersh parameter like below -

        // VIEWS: VISUALIZATION ELEMENTS
        //

        var element1 = new TableElement({
            "id": "element1",
            "refresh.auto.interval": "60",
            "managerid": "search1",
            "el": $('#element1')
        }, {tokens: true, tokenNamespace: "submitted"}).render();

        var element2 = new TableElement({
            "id": "element2",
            "refresh.auto.interval": "120",
            "managerid": "search2",
            "el": $('#element2')
        }, {tokens: true, tokenNamespace: "submitted"}).render();
0 Karma

niketn
Legend

Are you on 6.5 or higher and trying to refresh Panel? Can you try dashboard refresh instead?
In the JavaScript section add the following code before DASHBOARD READY comment:

setTimeout("location.reload();",60*1000);

//
// DASHBOARD READY
//
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

sillingworth
Path Finder

Yeah, I'm on 6.5.3 and it was the panel I'd set to refresh. Is your solution going to reload the whole page as though I'd pressed f5, or is it going to go through each panel and update it? Reloading the page means the browser spends several seconds rearranging everything, it's not seemless like panel refreshes.

0 Karma
Get Updates on the Splunk Community!

Building Reliable Asset and Identity Frameworks in Splunk ES

 Accurate asset and identity resolution is the backbone of security operations. Without it, alerts are ...

Cloud Monitoring Console - Unlocking Greater Visibility in SVC Usage Reporting

For Splunk Cloud customers, understanding and optimizing Splunk Virtual Compute (SVC) usage and resource ...

Automatic Discovery Part 3: Practical Use Cases

If you’ve enabled Automatic Discovery in your install of the Splunk Distribution of the OpenTelemetry ...