Expand description
EndpointsController — materializes Endpoints and EndpointSlice
objects from Service selectors + matching Pod IPs.
K8s rule: for each Service, find Pods in the same namespace
whose labels satisfy service.spec.selector AND are ready
AND have a status.podIP. Materialize one Endpoints object
(same name + namespace as the Service) with the Pod IPs in
subsets[].addresses.
§EndpointSlice (discovery.k8s.io/v1)
In addition to the legacy Endpoints object, the controller emits ONE
discovery.k8s.io/v1 EndpointSlice per Service — the modern endpoint-
publishing kind kube-proxy + many controllers consume. Both objects
are derived from the SAME selector→pod resolution (no fork): the slice
is a parallel projection of the identical (ip, pod_name) set. The
slice carries the upstream-required kubernetes.io/service-name label
- an owner reference back to the Service, and is named
<service>(engenho emits exactly one slice per Service; upstream shards into<service>-<hash>only above 1000 endpoints — a typed follow-up).
This is the FIRST selector-based controller in engenho-controllers (vs the owner-ref-based ReplicaSet/Deployment/GC). It validates that the Controller trait is general — the trait knows nothing about ownership; selector matching is just a different reconciliation predicate.