Replace standard json encoding with jsoniter
This commit is contained in:
parent
0fd87a7e56
commit
91ae204f6c
5 changed files with 25 additions and 7 deletions
|
|
@ -22,6 +22,8 @@ import (
|
|||
|
||||
"github.com/prometheus/client_golang/prometheus"
|
||||
|
||||
"k8s.io/apimachinery/pkg/util/sets"
|
||||
|
||||
"k8s.io/ingress-nginx/internal/ingress"
|
||||
"k8s.io/ingress-nginx/internal/ingress/annotations/class"
|
||||
"k8s.io/ingress-nginx/internal/ingress/metric/collectors"
|
||||
|
|
@ -38,6 +40,9 @@ type Collector interface {
|
|||
|
||||
SetSSLExpireTime([]*ingress.Server)
|
||||
|
||||
// SetHosts sets the hostnames that are being served by the ingress controller
|
||||
SetHosts(sets.String)
|
||||
|
||||
Start()
|
||||
Stop()
|
||||
}
|
||||
|
|
@ -138,3 +143,7 @@ func (c *collector) Stop() {
|
|||
func (c *collector) SetSSLExpireTime(servers []*ingress.Server) {
|
||||
c.ingressController.SetSSLExpireTime(servers)
|
||||
}
|
||||
|
||||
func (c *collector) SetHosts(hosts sets.String) {
|
||||
c.socket.SetHosts(hosts)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue