Ask HN: How does Kubernetes modify/add API endpoints at Runtime?

4 points by Kreotiko ↗ HN
I tried reading through the Kubernetes source code but can’t find low level documentation. Can anyone point me to the relevant bits?

2 comments

[ 2.6 ms ] story [ 12.9 ms ] thread
Do you mean with respect to balancing when endpoints come/go (e.g. a POD goes up/down)? Or something else?

In this case, it depends on the ingress controller used. The default nginx ingress case has some docs: https://kubernetes.github.io/ingress-nginx/how-it-works/

Note that nginx-ingress has limitations as a side effect of its Lua balancer vs normal nginx. As an example, it does NOT do TLS-resume on the nginx<->service hop. Normal nginx would, but the lua balancer lacks the necessary code [1]. In some high volume scenarios, this can cause trouble on the backend.

[1] https://github.com/openresty/lua-nginx-module/pull/1312

Thanks, I was actually interested in understanding how Kubernetes own API gets extended at runtime when you create a CRD