2013-03-11 Ramon Novoa <rnovoa@artica.es>
* util/pandora_xml_stress.pl: Added support for critical and warning thresholds. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7829 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
f2276e57b7
commit
fed3cdbcc4
|
@ -1,3 +1,8 @@
|
|||
2013-03-11 Ramon Novoa <rnovoa@artica.es>
|
||||
|
||||
* util/pandora_xml_stress.pl: Added support for critical and warning
|
||||
thresholds.
|
||||
|
||||
2013-03-07 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* lib/PandoraFMS/Core.pm: added in the start or end of downtimes
|
||||
|
|
|
@ -170,11 +170,29 @@ sub generate_xml_files ($$$$$$) {
|
|||
my $module_time_offset = get_generation_parameter($module, 'time_offset', '0');
|
||||
my $module_src = get_generation_parameter($module, 'src', 'source.txt');
|
||||
|
||||
my $module_min_critical = get_conf_token ($module, 'module_min_critical', '');
|
||||
my $module_max_critical = get_conf_token ($module, 'module_max_critical', '');
|
||||
my $module_min_warning = get_conf_token ($module, 'module_min_warning', '');
|
||||
my $module_max_warning = get_conf_token ($module, 'module_max_warning', '');
|
||||
|
||||
# Generate module data
|
||||
$xml_data .= "\t<module>\n";
|
||||
$xml_data .= "\t\t<name>$module_name</name>\n";
|
||||
$xml_data .= "\t\t<description>$module_description</description>\n";
|
||||
$xml_data .= "\t\t<type>$module_type</type>\n";
|
||||
|
||||
if ($module_min_critical ne '') {
|
||||
$xml_data .= "\t\t<min_critical>$module_min_critical</min_critical>\n";
|
||||
}
|
||||
if ($module_max_critical ne '') {
|
||||
$xml_data .= "\t\t<max_critical>$module_max_critical</max_critical>\n";
|
||||
}
|
||||
if ($module_min_warning ne '') {
|
||||
$xml_data .= "\t\t<min_warning>$module_min_warning</min_warning>\n";
|
||||
}
|
||||
if ($module_max_warning ne '') {
|
||||
$xml_data .= "\t\t<max_warning>$module_max_warning</max_warning>\n";
|
||||
}
|
||||
$xml_data .= "\t\t<unit><![CDATA[$module_unit]]></unit>\n";
|
||||
|
||||
# Generate data
|
||||
|
|
Loading…
Reference in New Issue