"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "cloudkitty/collector/monasca.py" between
cloudkitty-16.0.0.tar.gz and cloudkitty-17.0.0.tar.gz

About: OpenStack CloudKitty provides Rating-as-a-Service for OpenStack.
The "Zed" series (latest release).

monasca.py  (cloudkitty-16.0.0):monasca.py  (cloudkitty-17.0.0)
skipping to change at line 201 skipping to change at line 201
resource_key = metconf['extra_args']['resource_key'] resource_key = metconf['extra_args']['resource_key']
metadata = dict() metadata = dict()
if resources_info: if resources_info:
resource = resources_info[groupby[resource_key]] resource = resources_info[groupby[resource_key]]
for i in metconf['metadata']: for i in metconf['metadata']:
metadata[i] = resource.get(i, '') metadata[i] = resource.get(i, '')
qty = data['statistics'][0][1] qty = data['statistics'][0][1]
converted_qty = ck_utils.convert_unit( converted_qty = ck_utils.convert_unit(
qty, metconf['factor'], metconf['offset']) qty, metconf['factor'], metconf['offset'])
mutated_qty = ck_utils.mutate(converted_qty, metconf['mutate']) mutate_map = metconf.get('mutate_map')
mutated_qty = ck_utils.mutate(converted_qty, metconf['mutate'],
mutate_map=mutate_map)
return metadata, groupby, mutated_qty return metadata, groupby, mutated_qty
def fetch_all(self, metric_name, start, end, def fetch_all(self, metric_name, start, end,
project_id=None, q_filter=None): project_id=None, q_filter=None):
met = self.conf[metric_name] met = self.conf[metric_name]
data = self._fetch_measures( data = self._fetch_measures(
metric_name, metric_name,
start, start,
end, end,
 End of changes. 1 change blocks. 
1 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)