From 09dbed72f83c2e3de45c7129bd73db81135157f7 Mon Sep 17 00:00:00 2001 From: davidnewhall2 Date: Mon, 2 Dec 2019 19:40:29 -0800 Subject: [PATCH] comment cleanup --- pkg/promunifi/uap.go | 1 - pkg/promunifi/usg.go | 2 -- pkg/promunifi/usw.go | 4 +--- 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/pkg/promunifi/uap.go b/pkg/promunifi/uap.go index 108fea3f..40fe4891 100644 --- a/pkg/promunifi/uap.go +++ b/pkg/promunifi/uap.go @@ -80,7 +80,6 @@ type uap struct { } func descUAP(ns string) *uap { - // labels := []string{"type", "site_name", "name"} labelA := []string{"stat", "site_name", "name"} // stat + labels[1:] labelV := []string{"vap_name", "bssid", "radio", "radio_name", "essid", "usage", "site_name", "name"} labelR := []string{"radio_name", "radio", "site_name", "name"} diff --git a/pkg/promunifi/usg.go b/pkg/promunifi/usg.go index 03c6a12f..08282f37 100644 --- a/pkg/promunifi/usg.go +++ b/pkg/promunifi/usg.go @@ -36,8 +36,6 @@ type usg struct { } func descUSG(ns string) *usg { - // labels := []string{"version", "model", "serial", "type", "mac", "site_name", "name"} - // labelWan := append([]string{"port"}, labels[6:]...) labels := []string{"port", "site_name", "name"} return &usg{ WanRxPackets: prometheus.NewDesc(ns+"wan_receive_packets_total", "WAN Receive Packets Total", labels, nil), diff --git a/pkg/promunifi/usw.go b/pkg/promunifi/usw.go index 034b52db..c8d32581 100644 --- a/pkg/promunifi/usw.go +++ b/pkg/promunifi/usw.go @@ -47,8 +47,7 @@ type usw struct { func descUSW(ns string) *usw { pns := ns + "port_" - // labels := []string{"type", "site_name", "name"} - labelS := []string{"site_name", "name"} // labels[1:] + labelS := []string{"site_name", "name"} labelP := []string{"port_id", "port_num", "port_name", "port_mac", "port_ip", "site_name", "name"} return &usw{ SwRxPackets: prometheus.NewDesc(ns+"switch_receive_packets_total", "Switch Packets Received Total", labelS, nil), @@ -91,7 +90,6 @@ func descUSW(ns string) *usw { } func (u *promUnifi) exportUSW(r report, d *unifi.USW) { - labels := []string{d.Type, d.SiteName, d.Name} infoLabels := []string{d.Version, d.Model, d.Serial, d.Mac, d.IP, d.ID, d.Bytes.Txt} labelsGuest := append(labels, "guest")