Describe the bug
When using NGINX Plus with NGINX Gateway Fabric, the upstreams are applied correctly when HTTPRoute is applied via the API, but when the deployment is scaled, upstreams are removed incorrectly.
Expected behavior
The expected behavior is that upstreams are added correctly when HTTPRoute is added from API as well as when it is scaled. The curl request to tea should return bad gateway, but no errors should be reported in nginx error logs.
Your environment
Version of the NGINX Gateway Fabric - release version 1.2
Describe the bug When using NGINX Plus with NGINX Gateway Fabric, the upstreams are applied correctly when HTTPRoute is applied via the API, but when the deployment is scaled, upstreams are removed incorrectly.
To Reproduce Steps to reproduce the behavior:
Apply this example with updating
cafe.yaml
toCheck pods and tea pod will not be ready due to the readiness probe at port 1234
Check the NGINX Plus Dashboard at the forwarded port. You should see upstreams for both
tea
andcoffee
.Check the dashboard again, you will see only upstream for
coffee
and nottea
.When sending a curl request to
tea
, it return 502 which is expected behaviorCheck nginx logs
You should see error about no upstream available
Expected behavior The expected behavior is that upstreams are added correctly when HTTPRoute is added from API as well as when it is scaled. The curl request to tea should return bad gateway, but no errors should be reported in nginx error logs.
Your environment
Version of the NGINX Gateway Fabric - release version 1.2
Version of Kubernetes
Kubernetes platform - Kind
Details on how you expose the NGINX Gateway Fabric Pod - Added in reproducing steps
Logs of NGINX container:
kubectl -n nginx-gateway logs -l app=nginx-gateway -c nginx
kubectl -n nginx-gateway exec <gateway-pod> -c nginx -- nginx [-T
](ngf.txt)Additional context Add any other context about the problem here. Any log files you want to share.
Acceptance