pub enum SpreadScope {
Instance,
Role,
Cluster,
}Expand description
Which set of DNS Pods a spread rule balances across failure domains.
This is the field that makes zone spreading actually work in Bindy, and it exists because a DNS server is not an anonymous replica.
A Bind9Cluster with primary.replicas: 3 does not create one
three-Pod Deployment. Each primary is an individually addressable
nameserver (its hostname ends up in an NS record), so the cluster
controller creates three separate Bind9Instance resources, each backed by
its own single-Pod Deployment. A spread constraint whose label selector
matches only its own Deployment’s Pods would therefore balance a set of
size one — which is always trivially balanced, and spreads nothing.
scope selects the label selector the operator generates, and so decides
which Pods the scheduler counts per domain.
Variants§
Instance
Balance only the Pods of this one Bind9Instance.
Correct for a standalone Bind9Instance with spec.replicas: 2 or
more, where one Deployment really does own every Pod in the set.
A no-op for cluster-managed instances, which have one Pod each.
Role
Balance every Pod of the same role across the whole cluster.
Selects on bindy.firestoned.io/cluster + bindy.firestoned.io/role,
so all primaries of my-dns are balanced against each other (and all
secondaries separately against each other). This is the default for
cluster-managed instances and the setting that satisfies “spread
primaries across zones before stacking two in one zone”.
Cluster
Balance every Pod of the cluster, primaries and secondaries together.
Selects on bindy.firestoned.io/cluster alone. Useful when total DNS
footprint per zone matters more than per-role balance — for example
when primaries and secondaries are sized alike and you simply want an
even spread of nameservers per zone. Set it on both primary.placement
and secondary.placement so every Pod carries the same constraint.
Trait Implementations§
Source§impl Clone for SpreadScope
impl Clone for SpreadScope
Source§fn clone(&self) -> SpreadScope
fn clone(&self) -> SpreadScope
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SpreadScope
impl Debug for SpreadScope
Source§impl<'de> Deserialize<'de> for SpreadScope
impl<'de> Deserialize<'de> for SpreadScope
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for SpreadScope
impl JsonSchema for SpreadScope
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for SpreadScope
impl PartialEq for SpreadScope
Source§impl Serialize for SpreadScope
impl Serialize for SpreadScope
impl Copy for SpreadScope
impl Eq for SpreadScope
impl StructuralPartialEq for SpreadScope
Auto Trait Implementations§
impl Freeze for SpreadScope
impl RefUnwindSafe for SpreadScope
impl Send for SpreadScope
impl Sync for SpreadScope
impl Unpin for SpreadScope
impl UnwindSafe for SpreadScope
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].