heat : Remove cloudwatch functionalty from metadata server
Remove the cloudwatch metric functionality from the heat-metadata service, since all stats should now be sent via the CloudWatch api via the PutMetricData action (ref cfn-push-stats update) Note that after this change you will need to rebuild your jeos images to get the new version of cfn-push-stats from heat-jeos Signed-off-by: Steven Hardy <shardy@redhat.com> Change-Id: I5eec60d3dd0abfb32e2b4777635f1b0e2714a2c2
This commit is contained in:
parent
318f233c54
commit
4d262e3b29
|
@ -53,14 +53,6 @@ class API(wsgi.Router):
|
|||
mapper.connect('/events/',
|
||||
controller=metadata_controller, action='create_event',
|
||||
conditions=dict(method=['POST']))
|
||||
mapper.connect('/stats/:watch_name/data/',
|
||||
controller=metadata_controller,
|
||||
action='create_watch_data',
|
||||
conditions=dict(method=['PUT']))
|
||||
# mapper.connect('/stats/:watch_name/data/',
|
||||
# controller=metadata_controller,
|
||||
# action='list_watch_data',
|
||||
# conditions=dict(method=['GET']))
|
||||
|
||||
# TODO(shadower): make sure all responses are JSON-encoded
|
||||
# currently, calling an unknown route uses the default handler which
|
||||
|
|
|
@ -102,25 +102,6 @@ class MetadataController:
|
|||
return json_error(400, error)
|
||||
return json_response(201, event)
|
||||
|
||||
def create_watch_data(self, req, body, watch_name):
|
||||
con = context.get_admin_context()
|
||||
[error, watch_data] = self.engine_rpcapi.create_watch_data(con,
|
||||
watch_name=watch_name,
|
||||
stats_data=body)
|
||||
if error:
|
||||
return json_error(400, error)
|
||||
return json_response(201, watch_data)
|
||||
|
||||
def list_watch_data(self, req, watch_name):
|
||||
con = context.get_admin_context()
|
||||
data = self.engine_rpcapi.list_watch_data(con,
|
||||
watch_name=watch_name)
|
||||
if data:
|
||||
return data
|
||||
else:
|
||||
return json_error(404,
|
||||
'The watch "%s" does not exist.' % watch_name)
|
||||
|
||||
|
||||
def create_resource(options):
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue