mirror of
https://github.com/minio/minio.git
synced 2026-02-04 18:00:15 -05:00
Simplify access to local node name (#11907)
The local node name is heavily used in tracing, create a new global variable to store it. Multiple goroutines can access it since it won't be changed later.
This commit is contained in:
@@ -538,7 +538,7 @@ func storageMetricsPrometheus(ch chan<- prometheus.Metric) {
|
||||
}
|
||||
|
||||
server := getLocalServerProperty(globalEndpoints, &http.Request{
|
||||
Host: GetLocalPeer(globalEndpoints),
|
||||
Host: globalLocalNodeName,
|
||||
})
|
||||
|
||||
onlineDisks, offlineDisks := getOnlineOfflineDisksStats(server.Disks)
|
||||
|
||||
Reference in New Issue
Block a user