gnocchi: Remove archive-policy when creating metrics

Archive policy rules are created by the operator, and assign
archive policies to metrics at creation based on certain rules,
if there isn't an archive policy explicitly assigned to the
metric already.

This patch removes the explicit archive policy parameter when
creating the metrics, this means that the archive policy rules
defined by the oparator are respected.

Change-Id: Ie08df4e817fc701e4b524cdaaf181570fcc541f5
Related-Change: I562f62e1236c7c01c79a5e465ebec103c7bb07bd
This commit is contained in:
Emma Foley 2017-10-20 12:15:27 +00:00
parent ead2004b80
commit 40de219964

View File

@ -100,8 +100,7 @@ class Sender(common_sender.Sender):
def _create_metric(self, metername, endpoint, unit):
url = "{}/v1/metric/".format(endpoint)
payload = json.dumps({"archive_policy_name": "high",
"name": metername,
payload = json.dumps({"name": metername,
"unit": unit,
})
result = self._perform_request(url, payload, self._auth_token)