pub struct K8sVersionChain {
pub explicit: Vec<String>,
pub auto_fallback_window: Option<u32>,
}Expand description
Configuration for the in-provider K8s version chain.
Fields§
§explicit: Vec<String>User-supplied versions in their literal CLI order. The first is the primary, the rest are explicit fallbacks.
auto_fallback_window: Option<u32>Auto-extension policy: None = no auto-fallback;
Some(n) = append n minors below the smallest
explicit version, monotonically descending.
Implementations§
Source§impl K8sVersionChain
impl K8sVersionChain
Sourcepub fn new(
explicit: Vec<String>,
auto_fallback_window: Option<u32>,
) -> K8sVersionChain
pub fn new( explicit: Vec<String>, auto_fallback_window: Option<u32>, ) -> K8sVersionChain
Build a chain from explicit user-ordered versions and an
optional auto-fallback window. The two are combined as:
[explicit..., auto_fallback...]
where the auto-fallback list is a descending window of n minors
below the smallest explicit version. Auto-extension is only
valid when explicit.len() == 1 — the chain falls back to
“explicit only” for any other shape.
Sourcepub fn inference_scan_versions(&self) -> Vec<String>
pub fn inference_scan_versions(&self) -> Vec<String>
Versions that should participate in apiVersion-inference cache
scanning. This is explicit only — auto-fallback versions are
escape valves for legacy resources whose schemas exist only in
older K8s minors; they do NOT represent “what the user intends
to target”. Including them in inference would surface
historical apiVersions (policy/v1beta1, extensions/v1beta1,
…) for kinds whose modern version lives at the primary
version dir, producing spurious AmbiguousApiVersion
diagnostics.
Trait Implementations§
Source§impl Clone for K8sVersionChain
impl Clone for K8sVersionChain
Source§fn clone(&self) -> K8sVersionChain
fn clone(&self) -> K8sVersionChain
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more