From ab0a8f8cfd592c10b1aa4ab2856bdfc1049962e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lauri=20V=C3=B5sandi?= Date: Mon, 14 Jun 2021 22:02:30 +0300 Subject: [PATCH] Clean up metrics --- lease.py | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/lease.py b/lease.py index 2b32fe8..6982234 100755 --- a/lease.py +++ b/lease.py @@ -13,10 +13,22 @@ from sanic_wtf import SanicForm from wtforms import IntegerField, StringField from wtforms.validators import DataRequired, IPAddress, NumberRange -submit_count = Counter("pinecrypt_lease_submit", "IP updates", ["service"]) -flush_count = Counter("pinecrypt_lease_flush", "IP assignment flushes", ["service"]) -migration_count = Counter("pinecrypt_migration", "Client has migrated to this replica", ["replica"]) -not_found_count = Counter("pinecrypt_lease_not_found", "Certificate not found", ["service"]) +submit_count = Counter( + "pinecrypt_gateway_lease_updates", + "Client IP address updates.", + ["service"]) +flush_count = Counter( + "pinecrypt_gateway_lease_flushes", + "Client IP address flushes.", + ["service"]) +migration_count = Counter( + "pinecrypt_gateway_lease_migrations", + "Client migrations to this replica.", + ["replica"]) +not_found_count = Counter( + "pinecrypt_gateway_lease_not_found", + "Invalid connection attempts.", + ["service"]) class LeaseUpdateForm(SanicForm): service = StringField("Service name")