Class: CfnGuardian::Resource::Jenkins
- Defined in:
- lib/cfnguardian/resources/jenkins.rb
Instance Method Summary collapse
Methods inherited from Base
#default_checks, #default_event_subscriptions, #default_events, #default_metric_filters, #get_alarms, #get_checks, #get_cost, #get_event_subscriptions, #get_events, #get_metric_filters, #initialize, #resource_exists?
Methods included from Logging
colors, included, logger, #logger, logger=
Constructor Details
This class inherits a constructor from CfnGuardian::Resource::Base
Instance Method Details
#default_alarms ⇒ Object
3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/cfnguardian/resources/jenkins.rb', line 3 def default_alarms # evaluate this alarm every hour but only alert if there is no data point after 25 hours alarm = CfnGuardian::Models::JenkinsAlarm.new(@resource) alarm.name = 'HealthyAgent' alarm.metric_name = 'HealthyAgent' alarm.statistic = 'Maximum' alarm.treat_missing_data = 'breaching' alarm.alarm_action = 'Warning' alarm.period = 3600 # 1 hour alarm.evaluation_periods = 24 # 24 hours alarm.comparison_operator = 'LessThanThreshold' alarm.threshold = 1 @alarms.push(alarm) end |