Skip to main content

hash_container_name

Function hash_container_name 

Source
pub fn hash_container_name(pod_name: &str, container_name: &str) -> u64
Expand description

Hash a (pod, container) pair to get the same per-container instance ID a worker computes for itself under DYN_KUBE_DISCOVERY_MODE=container (see KubeDiscoveryTarget::Container). A container named "main" collapses to the pod-level identity (hash_pod_name), matching a container-mode frontend’s ability to discover pod-mode workers.

Used by the Rust EPP (deploy/inference-gateway/ext-proc) to resolve a registered worker’s per-container instance ID back to its pod’s endpoint when DYN_KUBE_DISCOVERY_MODE=container (e.g. intra-pod GMS failover, where each engine container registers under its own container name).