...
New Report Condition Elements in opConfig 4.2.1
...
Report Conditions has been extended to allow passing of structured data, this can be used to show urls, tooltips or buttons to kick off new virtual operator jobs.
Instead of returning a perl list you pass back an array of hashes.
Code Block |
---|
|
return { success => 1,
conditions => {
"ReportConditions" => [
{
message => "Interface has high util",
url => "http://example.com/kb/interface/util",
url_label => "KB Interface Util",
condition => 1,
}
],
},
}; |
Required values for condition elements
Key | Value |
---|
message | String - Message |
condition | 0 means a bad state for this condition, 1 means a good state for the condition, undef signals that the state of this condition is not known. |
URL Cell
You can have the conditions table render a URL cell in one or many rows.
Key | Value |
---|
url | http or https link |
url_label | Optional label for the link, if none if given then the url is displayed |

Code Block |
---|
|
push(@foundConditions, {
message=> "Interface $interface has HIGH percentage of INPUT packets being switched by the processor.",
url => "http://example.com/knowlege",
url_label => "Knowledge Base",
condition => 1,
}); |
Tooltips
Render a link which when the user clicks displays a tooltip.
Key | Value |
---|
Tooltip | String to render in the tooltip view |

Code Block |
---|
|
push(@foundConditions, {
message=>"Interface $interface has HIGH percentage of OUTPUT packets being switched by the processor.",
tooltip => "This is a bad thing, you should release the monkeys",
condition => 0,
}); |
Tagging
Key | Value |
---|
ts_tag | Tag to filter command sets by for creating a new virtual operator job |

Code Block |
---|
|
push(@foundConditions,{
message=>"Interface $interface has HIGH percentage of input errors.",
ts_tag=>'interface_errors',
condition => 1
}); |
...