This is an automated email from the ASF dual-hosted git repository.

zhangjintao pushed a commit to branch v1.5.0
in repository https://gitbox.apache.org/repos/asf/apisix-ingress-controller.git


The following commit(s) were added to refs/heads/v1.5.0 by this push:
     new 5a3ce7ca fix: ingress class not effect in resource sync logic (#1311) 
(#1330)
5a3ce7ca is described below

commit 5a3ce7ca526652055b65d48e7448102657022f4f
Author: Xin Rong <[email protected]>
AuthorDate: Wed Sep 14 16:34:38 2022 +0800

    fix: ingress class not effect in resource sync logic (#1311) (#1330)
    
    Co-authored-by: Xin Rong <[email protected]>
    Co-authored-by: xiangtianyu <[email protected]>
    Co-authored-by: Sarasa Kisaragi <[email protected]>
---
 pkg/ingress/ingress.go | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/pkg/ingress/ingress.go b/pkg/ingress/ingress.go
index aea2b990..67ec369a 100644
--- a/pkg/ingress/ingress.go
+++ b/pkg/ingress/ingress.go
@@ -416,6 +416,12 @@ func (c *ingressController) ResourceSync() {
                        continue
                }
                ing := kube.MustNewIngress(obj)
+               if !c.isIngressEffective(ing) {
+                       return
+               }
+               log.Debugw("ingress add event arrived",
+                       zap.Any("object", obj),
+               )
                c.workqueue.Add(&types.Event{
                        Type: types.EventAdd,
                        Object: kube.IngressEvent{

Reply via email to