Bases: object
Represents wrapper of any Ceilometer queries.
One instance of this class should be shared between resources as this class provides a place where users and tenants are cached. So there are no duplicate queries to API.
This class also wraps Ceilometer API calls and provides parallel HTTP calls to API.
This class should also serve as reasonable abstraction, that will cover huge amount of optimization due to optimization of Ceilometer service, without changing of the interface.
Returns tenant fetched from API.
Caching the result, so it doesn’t contact API twice with the same query.
Returns user fetched from API.
Caching the result, so it doesn’t contact API twice with the same query.
Obtaining a resources for table view.
It obtains resources with statistics data according to declaration in used_cls class.
Parameters: |
|
---|
Preloads all tenants into dictionary.
It’s more effective to preload all tenants, rather than fetching each tenant by separate API get calls.
Preloads all users into dictionary.
It’s more effective to preload all users, rather than fetching many users by separate API get calls.
Obtaining a query from resource id.
Query can be then used to identify a resource in resources or meters API calls. ID is being built in the Resource initializer, or returned by Datatable into UpdateRow functionality.
Obtaining resource aggregates with queries.
Representing a resource aggregate by query is a most general way how to obtain a resource aggregates.
Parameters: |
|
---|
Obtaining resource aggregates with statistics data inside.
Parameters: |
|
---|
Obtaining resources with the query or filter_func.
Obtains resources and also fetch tenants and users associated with those resources if with_users_and_tenants flag is true.
Parameters: |
|
---|
Obtaining resources with statistics data inside.
Parameters: |
|
---|
Adding statistical data into one Resource or ResourceAggregate.
It adds each statistic of each meter_names into the resource attributes. Attribute name is the meter name with replaced ‘.’ to ‘_’.
Parameters: |
|
---|
Bases: openstack_dashboard.api.base.APIResourceWrapper
Represents one Ceilometer meter.
Bases: object
Class for listing of available meters.
It is listing meters defined in this class that are available in Ceilometer meter_list.
It is storing information that is not available in Ceilometer, i.e. label, description.
Returns a list of meters based on the meters names.
Parameters: |
|
---|
Returns a list of meters tied to cinder.
Parameters: |
|
---|
Returns a list of meters tied to glance.
Parameters: |
|
---|
Returns a list of meters tied to ipmi
Parameters: |
|
---|
Returns a list of meters tied to kwapi.
Parameters: |
|
---|
Returns a list of meters tied to neutron.
Parameters: |
|
---|
Returns a list of meters tied to nova.
Parameters: |
|
---|
Returns a list of meters tied to swift.
Parameters: |
|
---|
Bases: openstack_dashboard.api.base.APIResourceWrapper
Represents one Ceilometer resource.
Bases: openstack_dashboard.api.ceilometer.Resource
Represents aggregate of more resources together.
Aggregate of resources can be obtained by specifying multiple ids in one parameter or by not specifying one parameter. It can also be specified by query directly.
Bases: openstack_dashboard.api.base.APIResourceWrapper
Represents one Ceilometer sample.
Bases: openstack_dashboard.api.base.APIResourceWrapper
Represents one Ceilometer statistic.
Bases: threading.Thread
Multithread wrapper for update_with_statistics method of resource_usage.
A join logic is placed in process_list class method. All resources will have its statistics attribute filled in separate threads.
The resource_usage object is shared between threads. Each thread is updating one Resource.
Parameters: |
|
---|
Initialization of Ceilometer client.
Return True if the given is list or tuple.
Returns query built from given parameters.
This query can be then used for querying resources, meters and statistics.
Parameters: |
|
---|
List the user’s meters.
List the resources.
List the samples for this meters.
List of statistics.