pub struct RemoteLink {
pub spool_id: String,
pub source_url: String,
pub direction: i32,
pub sync_interval: Option<Duration>,
pub next_sync_at: Option<Timestamp>,
pub auth_mode: i32,
pub enabled: bool,
pub status: i32,
pub last_synced_at: Option<Timestamp>,
pub last_error: String,
pub diverged_refs: Vec<String>,
pub honored_directions: Vec<i32>,
}Expand description
Durable remote configuration and sync health for one spool. direction is
what the caller configured, while honored_directions is what the serving
implementation will actually execute. Saving PUSH_TO_REMOTE or
BIDIRECTIONAL does not activate push: until weft#387, an enabled pull or
bidirectional link reports only FETCH_FROM_REMOTE, and a push-only or
disabled link reports no honored directions. SubmitOperation with
PUSH_TO_REMOTE continues to return UNIMPLEMENTED.
Fields§
§spool_id: String§source_url: String§direction: i32§sync_interval: Option<Duration>Absent means manual sync only.
next_sync_at: Option<Timestamp>Absent when no periodic sync is scheduled.
auth_mode: i32§enabled: bool§status: i32§last_synced_at: Option<Timestamp>§last_error: String§diverged_refs: Vec<String>§honored_directions: Vec<i32>Implementations§
Source§impl RemoteLink
impl RemoteLink
Sourcepub fn direction(&self) -> RemoteSyncDirection
pub fn direction(&self) -> RemoteSyncDirection
Returns the enum value of direction, or the default if the field is set to an invalid enum value.
Sourcepub fn set_direction(&mut self, value: RemoteSyncDirection)
pub fn set_direction(&mut self, value: RemoteSyncDirection)
Sets direction to the provided enum value.
Sourcepub fn auth_mode(&self) -> RemoteLinkAuthMode
pub fn auth_mode(&self) -> RemoteLinkAuthMode
Returns the enum value of auth_mode, or the default if the field is set to an invalid enum value.
Sourcepub fn set_auth_mode(&mut self, value: RemoteLinkAuthMode)
pub fn set_auth_mode(&mut self, value: RemoteLinkAuthMode)
Sets auth_mode to the provided enum value.
Sourcepub fn status(&self) -> RemoteLinkStatus
pub fn status(&self) -> RemoteLinkStatus
Returns the enum value of status, or the default if the field is set to an invalid enum value.
Sourcepub fn set_status(&mut self, value: RemoteLinkStatus)
pub fn set_status(&mut self, value: RemoteLinkStatus)
Sets status to the provided enum value.
Sourcepub fn honored_directions(
&self,
) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<RemoteSyncDirection>> ⓘ
pub fn honored_directions( &self, ) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<RemoteSyncDirection>> ⓘ
Returns an iterator which yields the valid enum values contained in honored_directions.
Sourcepub fn push_honored_directions(&mut self, value: RemoteSyncDirection)
pub fn push_honored_directions(&mut self, value: RemoteSyncDirection)
Appends the provided enum value to honored_directions.
Trait Implementations§
Source§impl Clone for RemoteLink
impl Clone for RemoteLink
Source§fn clone(&self) -> RemoteLink
fn clone(&self) -> RemoteLink
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RemoteLink
impl Debug for RemoteLink
Source§impl Default for RemoteLink
impl Default for RemoteLink
impl Eq for RemoteLink
Source§impl Hash for RemoteLink
impl Hash for RemoteLink
Source§impl Message for RemoteLink
impl Message for RemoteLink
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.