ceilometer.storage.impl_mongodb
Module¶MongoDB storage backend
ceilometer.storage.impl_mongodb.
Connection
(conf, url)[source]¶Bases: ceilometer.storage.pymongo_base.Connection
Put the data into a MongoDB database
Collections:
- meter
- the raw incoming data
- resource
- the metadata for resources
- { _id: uuid of resource,
metadata: metadata dictionaries
user_id: uuid
project_id: uuid
meter: [ array of {counter_name: string, counter_type: string,
counter_unit: string} ]
}
clear_expired_metering_data
(ttl)[source]¶Clear expired data from the backend storage system.
Clearing occurs with native MongoDB time-to-live feature.
get_meter_statistics
(sample_filter, period=None, groupby=None, aggregate=None)[source]¶Return an iterable of models.Statistics instance.
Items are containing meter statistics described by the query parameters. The filter must have a meter value set.
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
Parameters: |
|
---|
record_metering_data_batch
(samples)[source]¶Record the metering data in batch.
Parameters: | samples – a list of samples dict. |
---|
update_ttl
(ttl, ttl_index_name, index_field, coll)[source]¶Update or create time_to_live indexes.
Parameters: |
|
---|
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.