We are using gcp ingress gateway for our kubernetes cluster for public access url . Is there is any way or any specific annotation that can we use to restricts no of rps to our services.
We are using gcp ingress gateway for our kubernetes cluster for public access url . Is there is any way or any specific annotation that can we use to restricts no of rps to our services.
With the help of below annotation you can set the RPS in Nginx-ingress.
nginx.ingress.kubernetes.io/limit-rps
As an example below, the rate limit was set to 5 requests per second.
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
annotations:
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/limit-rps: "5"