All Apps and Add-ons
Highlighted

Web Monitoring

New Member

Regarding Website Monitoring and the page "Status Overview" is it possible to change the value when it should change color?

alt text

0 Karma
Highlighted

Re: Web Monitoring

Champion

You need to look at two files statusoverview.css and statusoverview.js at "/opt/splunk/etc/apps/website_monitoring/appserver/static".

0 Karma
Highlighted

Re: Web Monitoring

New Member

Thanks, for the answer and exactly the same two files I just found, 🙂 Couldn't directly see where but will copy them and open in a better application than a SSH window.

0 Karma
Highlighted

Re: Web Monitoring

New Member

Checked thru both files and can't find any specific for this.
If I look at the view so look it likes that it's
Green 0-100 (ms)
LightBlue 100-250
White 250-500
LightOrange 500-750
Orange 750-1000
Red 1000-
And it's these values I want to change

0 Karma
Highlighted

Re: Web Monitoring

Communicator

Unfortunately, this is a hardcoded setting to 1000ms at this time and is not something that can be dynamically set as you found.

You actually want the appserver/static/WebsiteStatusCellRenderer.js file. The section of code you are looking for is between lines 72 and 96. Adjust the else if statements to the times you are looking to have the 5 different percent values; 0, 25, 50, 75, 100. These percentages are used to drive two different aspects of the display.

  • The first is the shape of the stopwatch icon that is displayed and how full it is. This is on line 100 in WebsiteStatusCellRenderer.js. The stopwatch font is then set in appserver/static/status_overview.css in lines 166 to 176.
  • The second is the setting of the class of the table data (td.responsetime.response-+percent) set on line 105 in WebsiteStatusCellRenderer.js. This td class is then used in *appserver/static/statusoverview.css* in lines 115 to 143 to define the color of the cell.
0 Karma
Highlighted

Re: Web Monitoring

New Member

First problem is that I can't get any line feeds in the file, so it's just one long line.
But I have changed the values but I can't see any difference, does it need any kind of restart?

else{
if(f.field=="response_time"||f.field=="average"){var j=parseFloat(f.value,10);
if(j>=7000){l.addClass("failure");
g="alert"
}else
{l.addClass("success");var h=0;
if
(j<=100){h=0}
else
{
if(j<=500){h=25}
else
{
if(j<=1000){h=50}
else
{
if(j<=2500){h=75}
else
{
if(j<=7000){h=100}
else
{h=null}
}

0 Karma
Highlighted

Re: Web Monitoring

Communicator

Yes, you will need to restart Splunk on that instance. You may also need to clear your browser cache so it pulls down an updated file.

0 Karma
Highlighted

Re: Web Monitoring

New Member

Thank you for the help, worked perfectly after a restart.

0 Karma
Highlighted

Re: Web Monitoring

Communicator

You are welcome. Don't forget to mark my reply as the answer if it provided the help you needed.

0 Karma