The ceilometer.storage.base
Module¶
Base classes for storage engines
-
class
ceilometer.storage.base.
Connection
(conf, url)[source]¶ Bases:
object
Base class for storage system connections.
-
static
clear_expired_metering_data
(ttl)[source]¶ Clear expired data from the backend storage system.
Clearing occurs according to the time-to-live.
Parameters: ttl – Number of seconds to keep records for.
-
static
get_meter_statistics
(sample_filter, period=None, groupby=None, aggregate=None)[source]¶ Return an iterable of model.Statistics instances.
The filter must have a meter value set.
-
static
get_meters
(user=None, project=None, resource=None, source=None, metaquery=None, limit=None, unique=False)[source]¶ Return an iterable of model.Meter instances.
Iterable items containing meter information. :param user: Optional ID for user that owns the resource. :param project: Optional ID for project that owns the resource. :param resource: Optional resource filter. :param source: Optional source filter. :param metaquery: Optional dict with metadata to match on. :param limit: Maximum number of results to return. :param unique: If set to true, return only unique meter information.
-
static
get_resources
(user=None, project=None, source=None, start_timestamp=None, start_timestamp_op=None, end_timestamp=None, end_timestamp_op=None, metaquery=None, resource=None, limit=None)[source]¶ Return an iterable of models.Resource instances.
Iterable items containing resource information. :param user: Optional ID for user that owns the resource. :param project: Optional ID for project that owns the resource. :param source: Optional source filter. :param start_timestamp: Optional modified timestamp start range. :param start_timestamp_op: Optional timestamp start range operation. :param end_timestamp: Optional modified timestamp end range. :param end_timestamp_op: Optional timestamp end range operation. :param metaquery: Optional dict with metadata to match on. :param resource: Optional resource filter. :param limit: Maximum number of results to return.
-
static
get_samples
(sample_filter, limit=None)[source]¶ Return an iterable of model.Sample instances.
Parameters: - sample_filter – Filter.
- limit – Maximum number of results to return.
-
classmethod
get_storage_capabilities
()[source]¶ Return a dictionary representing the performance capabilities.
This is needed to evaluate the performance of each driver.
-
static
query_samples
(filter_expr=None, orderby=None, limit=None)[source]¶ Return an iterable of model.Sample objects.
Parameters: - filter_expr – Filter expression for query.
- orderby – List of field name and direction pairs for order by.
- limit – Maximum number of results to return.
-
static