You are here

function monitoring_icinga_service_description in Monitoring 7

Gets service description for Icinga.

This is vital for matching the generated service (sensor) config and submitting passive check.

Parameters

SensorInfo $sensor_info: Sensor info object.

Return value

string Icinga service description.

2 calls to monitoring_icinga_service_description()
monitoring_icinga_drush_callback in modules/monitoring_icinga/monitoring_icinga.drush.inc
Drush callback to get the sensor info.
monitoring_icinga_objects_definitions_output in modules/monitoring_icinga/monitoring_icinga.admin.inc
Creates the object definitions output part.

File

modules/monitoring_icinga/monitoring_icinga.module, line 61
Monitoring Nagios module bootstrap file.

Code

function monitoring_icinga_service_description(SensorInfo $sensor_info) {
  return $sensor_info
    ->getCategory() . ' - ' . $sensor_info
    ->getLabel() . ' - ' . $sensor_info
    ->getName();
}