Class: AWS::CloudWatch::Client

Inherits:
AWS::Core::QueryClient show all
Defined in:
lib/aws/cloud_watch/client.rb

Overview

Client class for Cloud Watch

Instance Attribute Summary

Attributes inherited from AWS::Core::Client

#config, #http_read_timeout

Instance Method Summary collapse

Methods inherited from AWS::Core::Client

#initialize, #log_warning, #operations, operations, #with_http_handler, #with_options

Constructor Details

This class inherits a constructor from AWS::Core::Client

Instance Method Details

#delete_alarms(options = {}) ⇒ Core::Response

Calls the DeleteAlarms API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_names - required - (Array<String>)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 32

#describe_alarm_history(options = {}) ⇒ Core::Response

Calls the DescribeAlarmHistory API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_name - (String)

    • :history_item_type - (String)

    • :start_date - (String<ISO8601 datetime>)

    • :end_date - (String<ISO8601 datetime>)

    • :max_records - (Integer)

    • :next_token - (String)

Returns:

  • (Core::Response)

    The #data method of the response object returns a hash with the following structure:

    • :alarm_history_items - (Array<Hash>)

      • :alarm_name - (String)

      • :timestamp - (Time)

      • :history_item_type - (String)

      • :history_summary - (String)

      • :history_data - (String)

    • :next_token - (String)



# File 'lib/aws/cloud_watch/client.rb', line 38

#describe_alarms(options = {}) ⇒ Core::Response

Calls the DescribeAlarms API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_names - (Array<String>)

    • :alarm_name_prefix - (String)

    • :state_value - (String)

    • :action_prefix - (String)

    • :max_records - (Integer)

    • :next_token - (String)

Returns:

  • (Core::Response)

    The #data method of the response object returns a hash with the following structure:

    • :metric_alarms - (Array<Hash>)

      • :alarm_name - (String)

      • :alarm_arn - (String)

      • :alarm_description - (String)

      • :alarm_configuration_updated_timestamp - (Time)

      • :actions_enabled - (Boolean)

      • :ok_actions - (Array<String>)

      • :alarm_actions - (Array<String>)

      • :insufficient_data_actions - (Array<String>)

      • :state_value - (String)

      • :state_reason - (String)

      • :state_reason_data - (String)

      • :state_updated_timestamp - (Time)

      • :metric_name - (String)

      • :namespace - (String)

      • :statistic - (String)

      • :dimensions - (Array<Hash>)

        • :name - (String)

        • :value - (String)

      • :period - (Integer)

      • :unit - (String)

      • :evaluation_periods - (Integer)

      • :threshold - (Numeric)

      • :comparison_operator - (String)

    • :next_token - (String)



# File 'lib/aws/cloud_watch/client.rb', line 58

#describe_alarms_for_metric(options = {}) ⇒ Core::Response

Calls the DescribeAlarmsForMetric API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :metric_name - required - (String)

    • :namespace - required - (String)

    • :statistic - (String)

    • :dimensions - (Array<Hash>)

      • :name - required - (String)

      • :value - required - (String)

    • :period - (Integer)

    • :unit - (String)

Returns:

  • (Core::Response)

    The #data method of the response object returns a hash with the following structure:

    • :metric_alarms - (Array<Hash>)

      • :alarm_name - (String)

      • :alarm_arn - (String)

      • :alarm_description - (String)

      • :alarm_configuration_updated_timestamp - (Time)

      • :actions_enabled - (Boolean)

      • :ok_actions - (Array<String>)

      • :alarm_actions - (Array<String>)

      • :insufficient_data_actions - (Array<String>)

      • :state_value - (String)

      • :state_reason - (String)

      • :state_reason_data - (String)

      • :state_updated_timestamp - (Time)

      • :metric_name - (String)

      • :namespace - (String)

      • :statistic - (String)

      • :dimensions - (Array<Hash>)

        • :name - (String)

        • :value - (String)

      • :period - (Integer)

      • :unit - (String)

      • :evaluation_periods - (Integer)

      • :threshold - (Numeric)

      • :comparison_operator - (String)



# File 'lib/aws/cloud_watch/client.rb', line 96

#disable_alarm_actions(options = {}) ⇒ Core::Response

Calls the DisableAlarmActions API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_names - required - (Array<String>)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 135

#enable_alarm_actions(options = {}) ⇒ Core::Response

Calls the EnableAlarmActions API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_names - required - (Array<String>)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 141

#get_metric_statistics(options = {}) ⇒ Core::Response

Calls the GetMetricStatistics API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :namespace - required - (String)

    • :metric_name - required - (String)

    • :dimensions - (Array<Hash>)

      • :name - required - (String)

      • :value - required - (String)

    • :start_time - required - (String<ISO8601 datetime>)

    • :end_time - required - (String<ISO8601 datetime>)

    • :period - required - (Integer)

    • :statistics - required - (Array<String>)

    • :unit - (String)

Returns:

  • (Core::Response)

    The #data method of the response object returns a hash with the following structure:

    • :label - (String)

    • :datapoints - (Array<Hash>)

      • :timestamp - (Time)

      • :sample_count - (Numeric)

      • :average - (Numeric)

      • :sum - (Numeric)

      • :minimum - (Numeric)

      • :maximum - (Numeric)

      • :unit - (String)



# File 'lib/aws/cloud_watch/client.rb', line 147

#list_metrics(options = {}) ⇒ Core::Response

Calls the ListMetrics API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :namespace - (String)

    • :metric_name - (String)

    • :dimensions - (Array<Hash>)

      • :name - required - (String)

      • :value - (String)

    • :next_token - (String)

Returns:

  • (Core::Response)

    The #data method of the response object returns a hash with the following structure:

    • :metrics - (Array<Hash>)

      • :namespace - (String)

      • :metric_name - (String)

      • :dimensions - (Array<Hash>)

        • :name - (String)

        • :value - (String)

    • :next_token - (String)



# File 'lib/aws/cloud_watch/client.rb', line 173

#put_metric_alarm(options = {}) ⇒ Core::Response

Calls the PutMetricAlarm API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_name - required - (String)

    • :alarm_description - (String)

    • :actions_enabled - (Boolean)

    • :ok_actions - (Array<String>)

    • :alarm_actions - (Array<String>)

    • :insufficient_data_actions - (Array<String>)

    • :metric_name - required - (String)

    • :namespace - required - (String)

    • :statistic - required - (String)

    • :dimensions - (Array<Hash>)

      • :name - required - (String)

      • :value - required - (String)

    • :period - required - (Integer)

    • :unit - (String)

    • :evaluation_periods - required - (Integer)

    • :threshold - required - (Float)

    • :comparison_operator - required - (String)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 193

#put_metric_data(options = {}) ⇒ Core::Response

Calls the PutMetricData API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :namespace - required - (String)

    • :metric_data - required - (Array<Hash>)

      • :metric_name - required - (String)

      • :dimensions - (Array<Hash>)

        • :name - required - (String)

        • :value - required - (String)

      • :timestamp - (String<ISO8601 datetime>)

      • :value - (Float)

      • :statistic_values - (Hash)

        • :sample_count - required - (Float)

        • :sum - required - (Float)

        • :minimum - required - (Float)

        • :maximum - required - (Float)

      • :unit - (String)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 215

#set_alarm_state(options = {}) ⇒ Core::Response

Calls the SetAlarmState API operation.

Parameters:

  • options (Hash) (defaults to: {})
    • :alarm_name - required - (String)

    • :state_value - required - (String)

    • :state_reason - required - (String)

    • :state_reason_data - (String)

Returns:



# File 'lib/aws/cloud_watch/client.rb', line 234