pyrax
Python Bindings for the Rackspace Cloud
|
Represents a check defined for an entity. More...
Public Member Functions | |
def | __init__ |
def | name |
def | get |
Reloads the check with its current values. | |
def | update |
Updates an existing check with any of the parameters. | |
def | delete |
Removes this check from its entity. | |
def | list_metrics |
Returns a list of all the metrics associated with this check. | |
def | get_metric_data_points |
Returns the data points for a given metric for the given period. | |
def | create_alarm |
Creates an alarm that binds this check with a notification plan. | |
Public Attributes | |
entity | |
Static Public Attributes | |
reload = get |
Represents a check defined for an entity.
def __init__ | ( | self, | |
manager, | |||
info, | |||
entity, | |||
key = None , |
|||
loaded = False |
|||
) |
def create_alarm | ( | self, | |
notification_plan, | |||
criteria = None , |
|||
disabled = False , |
|||
label = None , |
|||
name = None , |
|||
metadata = None |
|||
) |
Creates an alarm that binds this check with a notification plan.
def delete | ( | self | ) |
Removes this check from its entity.
Reimplemented from BaseResource.
def get | ( | self | ) |
Reloads the check with its current values.
Reimplemented from BaseResource.
def get_metric_data_points | ( | self, | |
metric, | |||
start, | |||
end, | |||
points = None , |
|||
resolution = None , |
|||
stats = None |
|||
) |
Returns the data points for a given metric for the given period.
The 'start' and 'end' times must be specified; they can be be either Python date/datetime values, or a Unix timestamp.
The 'points' parameter represents the number of points to return. The 'resolution' parameter represents the granularity of the data. You must specify either 'points' or 'resolution'. The allowed values for resolution are: FULL MIN5 MIN20 MIN60 MIN240 MIN1440
Finally, the 'stats' parameter specifies the stats you want returned. By default only the 'average' is returned. You omit this parameter, pass in a single value, or pass in a list of values. The allowed values are: average variance min max
def list_metrics | ( | self | ) |
Returns a list of all the metrics associated with this check.
def name | ( | self | ) |
def update | ( | self, | |
label = None , |
|||
name = None , |
|||
disabled = None , |
|||
metadata = None , |
|||
monitoring_zones_poll = None , |
|||
timeout = None , |
|||
period = None , |
|||
target_alias = None , |
|||
target_hostname = None , |
|||
target_receiver = None |
|||
) |
Updates an existing check with any of the parameters.
Reimplemented from BaseResource.