<p>I have been getting alerts that a few APIs were deprecated in v1.22 of Kubernetes cluster in GCP and so I changed all of my deployments and nginx controllers to version apps/v1 and networking.k8s.io/v1 . But my cluster still shows that there are some components using the deprecated api's.
The error on the pod is -</p>
<pre><code>k8s.io/client-go@v0.18.6/tools/cache/reflector.go:125: Failed to list *v1beta1.Ingress: the server could not find the requested resource
</code></pre>
<p>The deprecated apis called are -
API :</p>
<pre><code>/apis/networking.k8s.io/v1beta1/ingresses
</code></pre>
<p>for user agent -</p>
<pre><code>nginx-ingress-controller/v0.35.0 (linux/amd64) ingress-nginx/54ad65e32bcab32791ab18531a838d1c0f0811ef
</code></pre>
<p>and</p>
<pre><code>/apis/networking.k8s.io/v1beta1/ingressclasses
</code></pre>
<p>for</p>
<pre><code>nginx-ingress-controller/v0.35.0 (linux/amd64) ingress-nginx/54ad65e32bcab32791ab18531a838d1c0f0811ef
</code></pre>
<p>Today some of deployments were unable to reach from the browser, what changes do I need to make.</p>

Jainam Shah
<p>The root cause of the issue is that the <strong>NGINX Controller has to be compatible with the kubernetes version</strong>.</p>
<p><strong>Follow resolutions steps below :</strong></p>
<ol>
<li><p>Check the version of NGINX.</p>
</li>
<li><p>Check Kubernetes version GKE console in GCP UI.</p>
</li>
<li><p>Confirm the supported versions with kubernetes <a href="https://github.com/kubernetes/ingress-nginx#support-versions-table" rel="nofollow noreferrer">here</a>.</p>
</li>
<li><p>Update NGINX (change the API version of NGINX Ingress)</p>
</li>
</ol>
<p><strong>If NGINX was installed using Helm, its name will be ingress-nginx, and it can be upgraded using a helm command like below:</strong></p>
<pre><code>helm upgrade --reuse-values ingress-nginx ingress-nginx/ingress-nginx
</code></pre>
<p>You can also refer to the GCP official doc <a href="https://cloud.google.com/kubernetes-engine/docs/deprecations/apis-1-22#ingress-v122" rel="nofollow noreferrer">Upgrading third-party components</a> and similar <a href="https://github.com/bitnami/charts/issues/7264" rel="nofollow noreferrer">Github issue</a> for relevant info, which may help to resolve your issue.</p>
