Revert "Add metrics for nodes online and offline (#11050)"

This reverts commit f60bbdf86b.
This commit is contained in:
Harshavardhana
2020-12-08 09:23:35 -08:00
parent 6b7ced80fe
commit 4a564336fe
4 changed files with 31 additions and 88 deletions
+2 -17
View File
@@ -51,8 +51,8 @@ type NotificationSys struct {
targetResCh chan event.TargetIDResult
bucketRulesMap map[string]event.RulesMap
bucketRemoteTargetRulesMap map[string]map[event.TargetID]event.RulesMap
peerClients []*peerRESTClient // Excludes self
allPeerClients []*peerRESTClient // Includes nil client for self
peerClients []*peerRESTClient
allPeerClients []*peerRESTClient
}
// GetARNList - returns available ARNs.
@@ -1288,21 +1288,6 @@ func NewNotificationSys(endpoints EndpointServerPools) *NotificationSys {
}
}
// GetPeerOnlineCount gets the count of online and offline nodes.
func GetPeerOnlineCount() (nodesOnline, nodesOffline int) {
nodesOnline = 1
nodesOffline = 0
servers := globalNotificationSys.ServerInfo()
for _, s := range servers {
if s.State == "online" {
nodesOnline++
continue
}
nodesOffline++
}
return
}
type eventArgs struct {
EventName event.Name
BucketName string