Skip to content

Commit a2067e0

Browse files
committed
Removed fortigate_network_dns_latest_update
Signed-off-by: Örnfeldt Philip (66140321) <philip.ornfeldt@forsakringskassan.se>
1 parent d33031b commit a2067e0

3 files changed

Lines changed: 0 additions & 10 deletions

File tree

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ Global:
3939

4040
* _Network/Dns/Latency_
4141
* `fortigate_network_dns_latency_`
42-
* `fortigate_network_dns_latest_update`
4342
* _System/SensorInfo_
4443
* `fortigate_sensor_alarm_status`
4544
* `fortigate_sensor_fan_rpm`

pkg/probe/network_dns_latency.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,6 @@ func probeNetworkDnsLatency(c http.FortiHTTP, meta *TargetMetadata) ([]prometheu
2727
"Network dns latency",
2828
[]string{"service", "ip"}, nil,
2929
)
30-
dnsLastUpdate = prometheus.NewDesc(
31-
"fortigate_network_dns_latest_update",
32-
"Network dns last record update",
33-
[]string{"service", "ip"}, nil,
34-
)
3530
)
3631

3732
type DnsLatencty struct {
@@ -53,7 +48,6 @@ func probeNetworkDnsLatency(c http.FortiHTTP, meta *TargetMetadata) ([]prometheu
5348
m := []prometheus.Metric{}
5449
for _, r := range res.Results {
5550
m = append(m, prometheus.MustNewConstMetric(dnsLatency, prometheus.GaugeValue, r.Latency * 0.001, r.Service, r.Ip))
56-
m = append(m, prometheus.MustNewConstMetric(dnsLastUpdate, prometheus.GaugeValue, r.LastUpdate, r.Service, r.Ip))
5751
}
5852

5953
return m, true

pkg/probe/network_dns_latency_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,6 @@ func TestNetworkDnsLatency(t *testing.T) {
3232
# HELP fortigate_network_dns_latency_seconds Network dns latency
3333
# TYPE fortigate_network_dns_latency_seconds gauge
3434
fortigate_network_dns_latency_seconds{ip="8.8.8.8",service="dns_server"} 0.01
35-
# HELP fortigate_network_dns_latest_update Network dns last record update
36-
# TYPE fortigate_network_dns_latest_update gauge
37-
fortigate_network_dns_latest_update{ip="8.8.8.8",service="dns_server"} 1040
3835
`
3936

4037
if err := testutil.GatherAndCompare(r, strings.NewReader(em)); err != nil {

0 commit comments

Comments
 (0)