From 394a3fe1e6143f2bddd4bc46863316810cadcb40 Mon Sep 17 00:00:00 2001 From: aphralG <108004222+aphralG@users.noreply.github.com> Date: Tue, 26 Sep 2023 17:23:25 +0100 Subject: [PATCH] remove error log causing failures (#488) * remove error log --- src/core/nginx.go | 10 ---------- .../vendor/github.com/nginx/agent/v2/src/core/nginx.go | 10 ---------- .../vendor/github.com/nginx/agent/v2/src/core/nginx.go | 10 ---------- 3 files changed, 30 deletions(-) diff --git a/src/core/nginx.go b/src/core/nginx.go index a1dda677e..04dcc944e 100644 --- a/src/core/nginx.go +++ b/src/core/nginx.go @@ -123,25 +123,15 @@ func (n *NginxBinaryType) UpdateNginxDetailsFromProcesses(nginxProcesses []*Proc n.statusUrls = map[string]string{} n.statusUrlMutex.Unlock() - numberOfMasterProcesses := 0 - for _, process := range nginxProcesses { nginxDetails := n.GetNginxDetailsFromProcess(process) if process.IsMaster { - numberOfMasterProcesses++ n.nginxDetailsMap[nginxDetails.GetNginxId()] = nginxDetails } else { n.nginxWorkersMap[nginxDetails.GetNginxId()] = append(n.nginxWorkersMap[nginxDetails.GetNginxId()], nginxDetails) } } - if len(n.nginxDetailsMap) != numberOfMasterProcesses { - log.Errorf( - "Multiple NGINX master processes detected with the same NGINX ID. Number of master processes is %d. Number of unique NGINX IDs is %d.", - numberOfMasterProcesses, - len(n.nginxDetailsMap), - ) - } } func (n *NginxBinaryType) GetChildProcesses() map[string][]*proto.NginxDetails { diff --git a/test/integration/vendor/github.com/nginx/agent/v2/src/core/nginx.go b/test/integration/vendor/github.com/nginx/agent/v2/src/core/nginx.go index a1dda677e..04dcc944e 100644 --- a/test/integration/vendor/github.com/nginx/agent/v2/src/core/nginx.go +++ b/test/integration/vendor/github.com/nginx/agent/v2/src/core/nginx.go @@ -123,25 +123,15 @@ func (n *NginxBinaryType) UpdateNginxDetailsFromProcesses(nginxProcesses []*Proc n.statusUrls = map[string]string{} n.statusUrlMutex.Unlock() - numberOfMasterProcesses := 0 - for _, process := range nginxProcesses { nginxDetails := n.GetNginxDetailsFromProcess(process) if process.IsMaster { - numberOfMasterProcesses++ n.nginxDetailsMap[nginxDetails.GetNginxId()] = nginxDetails } else { n.nginxWorkersMap[nginxDetails.GetNginxId()] = append(n.nginxWorkersMap[nginxDetails.GetNginxId()], nginxDetails) } } - if len(n.nginxDetailsMap) != numberOfMasterProcesses { - log.Errorf( - "Multiple NGINX master processes detected with the same NGINX ID. Number of master processes is %d. Number of unique NGINX IDs is %d.", - numberOfMasterProcesses, - len(n.nginxDetailsMap), - ) - } } func (n *NginxBinaryType) GetChildProcesses() map[string][]*proto.NginxDetails { diff --git a/test/performance/vendor/github.com/nginx/agent/v2/src/core/nginx.go b/test/performance/vendor/github.com/nginx/agent/v2/src/core/nginx.go index a1dda677e..04dcc944e 100644 --- a/test/performance/vendor/github.com/nginx/agent/v2/src/core/nginx.go +++ b/test/performance/vendor/github.com/nginx/agent/v2/src/core/nginx.go @@ -123,25 +123,15 @@ func (n *NginxBinaryType) UpdateNginxDetailsFromProcesses(nginxProcesses []*Proc n.statusUrls = map[string]string{} n.statusUrlMutex.Unlock() - numberOfMasterProcesses := 0 - for _, process := range nginxProcesses { nginxDetails := n.GetNginxDetailsFromProcess(process) if process.IsMaster { - numberOfMasterProcesses++ n.nginxDetailsMap[nginxDetails.GetNginxId()] = nginxDetails } else { n.nginxWorkersMap[nginxDetails.GetNginxId()] = append(n.nginxWorkersMap[nginxDetails.GetNginxId()], nginxDetails) } } - if len(n.nginxDetailsMap) != numberOfMasterProcesses { - log.Errorf( - "Multiple NGINX master processes detected with the same NGINX ID. Number of master processes is %d. Number of unique NGINX IDs is %d.", - numberOfMasterProcesses, - len(n.nginxDetailsMap), - ) - } } func (n *NginxBinaryType) GetChildProcesses() map[string][]*proto.NginxDetails {