diff --git a/library/Director/Web/Form/DirectorObjectForm.php b/library/Director/Web/Form/DirectorObjectForm.php index f5adf96a..913da859 100644 --- a/library/Director/Web/Form/DirectorObjectForm.php +++ b/library/Director/Web/Form/DirectorObjectForm.php @@ -1354,6 +1354,34 @@ abstract class DirectorObjectForm extends DirectorForm $this->translate('Whether to process performance data provided by this object') ); + $this->optionalBoolean( + 'enable_flapping', + $this->translate('Enable flap detection'), + $this->translate('Whether flap detection is enabled on this object') + ); + + $this->addElement( + 'text', + 'flapping_threshold_high', + array( + 'label' => $this->translate('Flapping threshold (high)'), + 'description' => $this->translate( + 'Flapping upper bound in percent for a service to be considered flapping' + ) + ) + ); + + $this->addElement( + 'text', + 'flapping_threshold_low', + array( + 'label' => $this->translate('Flapping threshold (low)'), + 'description' => $this->translate( + 'Flapping lower bound in percent for a service to be considered not flapping' + ) + ) + ); + $this->optionalBoolean( 'volatile', $this->translate('Volatile'), @@ -1371,6 +1399,9 @@ abstract class DirectorObjectForm extends DirectorForm 'enable_notifications', 'enable_event_handler', 'enable_perfdata', + 'enable_flapping', + 'flapping_threshold_high', + 'flapping_threshold_low', 'volatile' ); $this->addToCheckExecutionDisplayGroup($elements);