def _parameter_valuespec_ibm_mq_managers(): return Dictionary(elements=[ ( "mapped_states", ListOf( Tuple( orientation="horizontal", elements=[ DropdownChoice( title=_("Queue manager state"), choices=[ ("starting", "STARTING"), ("running", "RUNNING"), ("running_as_standby", "RUNNING AS STANDBY"), ("running_elsewhere", "RUNNING ELSEWHERE"), ("quiescing", "QUIESCING"), ("ending_immediately", "ENDING IMMEDIATELY"), ("ending_pre_emptively", "ENDING PRE-EMPTIVLEY"), ("ended_normally", "ENDED NORMALLY"), ("ended_immediately", "ENDED IMMEDIATELY"), ("ended_unexpectedly", "ENDED UNEXPECTEDLY"), ("ended_pre_emptively", "ENDED PRE-EMPTIVELY"), ("status_not_available", "STATUS NOT AVAILABLE"), ], ), MonitoringState(title=_("Service state"), ), ], ), title=_("Map manager state to service state"), help=_( """If you do not use this parameter, the following factory defaults apply:<br> STARTING: OK<br> RUNNING: OK<br> RUNNING AS STANDBY: OK<br> RUNNING ELSEWHERE: OK<br> QUIESCING: OK<br> ENDING IMMEDIATELY: OK<br> ENDING PRE-EMPTIVELY: OK<br> ENDED NORMALLY: OK<br> ENDED IMMEDIATELY: OK<br> ENDED UNEXPECTEDLY: CRIT<br> ENDED PRE-EMPTIVELY: WARN<br> STATUS NOT AVAILABLE: OK<br> """), ), ), ( "mapped_states_default", MonitoringState(title=_("Service state if no map rule matches"), default_value=2), ), ] + ibm_mq_version(), )
def _parameter_valuespec_ibm_mq_managers(): return Dictionary(elements=[ ("status", Dictionary( title=_('Override check state based on queue manager state'), elements=[ ("STARTING", MonitoringState(title=_("When STARTING"), default_value=0)), ("RUNNING", MonitoringState(title=_("When RUNNING"), default_value=0)), ("RUNNING AS STANDBY", MonitoringState(title=_("When RUNNING AS STANDBY"), default_value=0)), ("RUNNING ELSEWHERE", MonitoringState(title=_("When RUNNING ELSEWHERE"), default_value=0)), ("QUIESCING", MonitoringState(title=_("When QUIESCING"), default_value=0)), ("ENDING IMMEDIATELY", MonitoringState(title=_("When ENDING IMMEDIATELY"), default_value=0)), ("ENDING PREEMPTIVELY", MonitoringState(title=_("When ENDING PREEMPTIVELY"), default_value=0)), ("ENDING PRE-EMPTIVELY", MonitoringState(title=_("When ENDING PRE-EMPTIVELY"), default_value=0)), ("ENDED NORMALLY", MonitoringState(title=_("When ENDED NORMALLY"), default_value=0)), ("ENDED IMMEDIATELY", MonitoringState(title=_("When ENDED IMMEDIATELY"), default_value=0)), ("ENDED UNEXPECTEDLY", MonitoringState(title=_("When UNEXPECTEDLY"), default_value=2)), ("ENDED PREEMPTIVELY", MonitoringState(title=_("When ENDED PREEMPTIVELY"), default_value=2)), ("ENDED PRE-EMPTIVELY", MonitoringState(title=_("When ENDED PRE-EMPTIVELY"), default_value=2)), ("NOT AVAILABLE", MonitoringState(title=_("When NOT AVAILABLE"), default_value=0)), ("STATUS NOT AVAILABLE", MonitoringState(title=_("When STATUS NOT AVAILABLE"), default_value=0)), ], optional_keys=[])), ] + ibm_mq_version(), )