nginx can't implement session stickiness with nodeport services, must be clusterip?
David Karr
davidmichaelkarr at gmail.com
Fri Mar 8 19:18:10 UTC 2024
I maintain the Java side of a platform that supports a couple of hundred
services running in a number of k8s clusters. Each pod has a container
running the Java process, and a container running nginx, as a proxy to the
Java service. All the k8s service objects are type NodePort, not ClusterIP.
I don't know a lot about nginx, we consider it mostly a blackbox.
We have one service that unfortunately requires session stickiness. I am
being told that we have to change the service type for this service to
ClusterIP, because, and I quote the person who told me this:
"Nginx needs to be able to read the "endpoint" objects off of the
service. For some reason, that's not possible with NodePorts, but works
fine with ClusterIPs."
Does this make sense to anyone here? Can someone explain why this might be?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20240308/b9a5413c/attachment.htm>
More information about the nginx
mailing list