Documentation
¶
Overview ¶
Package membership is the LIVE writer-membership source: the K8s Endpoints poll that plugs into internal/org's Source seam so the horizontally-scaled cloud tracks its CHANGING pod set instead of a static list.
It lives OUT of package cloud on purpose. Every subsystem imports cloud for Deps, so cloud's import graph is the floor under all of them; the k8s client pulls 263 packages that only this one file needed. cloud declares the seam (cloud.SetLiveSource) and apps/ installs K8s into it, so a subsystem — and cloud's own tests — compile without the Kubernetes client present at all.
It is the fix for the rolling-upgrade outage: with a static peer set, ha.Owner keeps electing a pod that is draining or already gone, and the shard router forwards an org's requests to a dead pod; a live, READY-gated set drops that pod the moment it starts terminating, so ha.Owner re-elects a live successor and the org stays served.
It is a bounded LIST poll driven by internal/org.Membership's existing refresh loop (which retains the last-good set on a transient error and serves the hot-path AmOwner check lock-free from an atomic snapshot). Each poll re-lists, so a dropped connection self-heals on the next tick — no watch state to wedge.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.