Struct garage_rpc::layout::NodeRole
source · pub struct NodeRole {
pub zone: String,
pub capacity: Option<u32>,
pub tags: Vec<String>,
}
Expand description
The user-assigned roles of cluster nodes
Fields§
§zone: String
Datacenter at which this entry belong. This information might be used to perform a better geodistribution
capacity: Option<u32>
The (relative) capacity of the node If this is set to None, the node does not participate in storing data for the system and is only active as an API gateway to other nodes
A set of tags to recognize the node
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for NodeRole
impl<'de> Deserialize<'de> for NodeRole
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>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for NodeRole
impl Ord for NodeRole
source§impl PartialEq<NodeRole> for NodeRole
impl PartialEq<NodeRole> for NodeRole
source§impl PartialOrd<NodeRole> for NodeRole
impl PartialOrd<NodeRole> for NodeRole
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for NodeRole
impl StructuralEq for NodeRole
impl StructuralPartialEq for NodeRole
Auto Trait Implementations§
impl RefUnwindSafe for NodeRole
impl Send for NodeRole
impl Sync for NodeRole
impl Unpin for NodeRole
impl UnwindSafe for NodeRole
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.