pub struct SyncMetadata {
pub sync_id: String,
pub strategy: SyncStrategy,
pub status: SyncStatus,
pub started_at: DateTime<Utc>,
pub completed_at: Option<DateTime<Utc>>,
pub items_synced: usize,
pub bytes_transferred: usize,
pub error: Option<String>,
}Expand description
Sync metadata
Fields§
§sync_id: StringUnique sync ID
strategy: SyncStrategySync strategy used
status: SyncStatusSync status
started_at: DateTime<Utc>Start timestamp
completed_at: Option<DateTime<Utc>>Completion timestamp
items_synced: usizeNumber of items synced
bytes_transferred: usizeTotal bytes transferred
error: Option<String>Error message if failed
Implementations§
Source§impl SyncMetadata
impl SyncMetadata
Sourcepub fn new(sync_id: String, strategy: SyncStrategy) -> Self
pub fn new(sync_id: String, strategy: SyncStrategy) -> Self
Create new sync metadata
Sourcepub fn throughput(&self) -> Option<f64>
pub fn throughput(&self) -> Option<f64>
Get throughput in bytes per second
Trait Implementations§
Source§impl Clone for SyncMetadata
impl Clone for SyncMetadata
Source§fn clone(&self) -> SyncMetadata
fn clone(&self) -> SyncMetadata
Returns a duplicate of the value. Read more
1.0.0 · 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 SyncMetadata
impl Debug for SyncMetadata
Source§impl<'de> Deserialize<'de> for SyncMetadata
impl<'de> Deserialize<'de> for SyncMetadata
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
Auto Trait Implementations§
impl Freeze for SyncMetadata
impl RefUnwindSafe for SyncMetadata
impl Send for SyncMetadata
impl Sync for SyncMetadata
impl Unpin for SyncMetadata
impl UnsafeUnpin for SyncMetadata
impl UnwindSafe for SyncMetadata
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