pub struct StaticPeer {
pub id: u64,
pub api_addr: SocketAddr,
pub os: String,
pub labels: HashMap<String, String>,
}Expand description
A static-cluster peer’s identity, reachability, and labels.
Fields§
§id: u64§api_addr: SocketAddrHTTP API address (host:port). Heartbeats land on this address
at /health; cluster dispatch lands at /api/v1/internal/scale.
os: StringOperating system this peer runs ("linux" / "windows" / "darwin").
Used by placement when filtering nodes for a service’s OsKind.
labels: HashMap<String, String>Free-form labels.
Trait Implementations§
Source§impl Clone for StaticPeer
impl Clone for StaticPeer
Source§fn clone(&self) -> StaticPeer
fn clone(&self) -> StaticPeer
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StaticPeer
impl Debug for StaticPeer
Source§impl<'de> Deserialize<'de> for StaticPeer
impl<'de> Deserialize<'de> for StaticPeer
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
impl Eq for StaticPeer
Source§impl PartialEq for StaticPeer
impl PartialEq for StaticPeer
Source§fn eq(&self, other: &StaticPeer) -> bool
fn eq(&self, other: &StaticPeer) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for StaticPeer
impl Serialize for StaticPeer
impl StructuralPartialEq for StaticPeer
Auto Trait Implementations§
impl Freeze for StaticPeer
impl RefUnwindSafe for StaticPeer
impl Send for StaticPeer
impl Sync for StaticPeer
impl Unpin for StaticPeer
impl UnsafeUnpin for StaticPeer
impl UnwindSafe for StaticPeer
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.