Skip to main content

validate_foreign_snapshots_cluster_coupling

Function validate_foreign_snapshots_cluster_coupling 

Source
pub fn validate_foreign_snapshots_cluster_coupling(
    catalog: Option<&CatalogBounds>,
    cluster: Option<&str>,
) -> Vec<ValidationError>
Expand description

The identityDefaults.cluster × catalog.foreignSnapshots cross-field rules (multi-cluster shared-repo): classifying a snapshot as another cluster’s is undecidable without a cluster identity (a), and adopting one must never silently switch off an already-configured fallback collector (d). Shared by both repository kinds — cluster is the resolved identityDefaults.cluster value, None when the repository has no cluster identity set (or, on a namespaced Repository, no identityDefaults set at all). Without a cluster, rule (d) is a no-op (it requires one to fire) while rule (a) still rejects any foreignSnapshots set there.