pub struct FfiSyncEntry {
pub album_id: Vec<u8>,
pub manifest_cbor: Vec<u8>,
pub metadata_blob: Vec<u8>,
pub original_ciphertext: Vec<u8>,
pub local_chain_head: Option<Vec<u8>>,
}Expand description
One remote feed entry to apply, as a sync feed delivers it.
album_id and the two id-bearing fields carry the feed’s own 16-byte UUID form (the
bytes album_id of capsule.sync.v1.SyncEntry), so an entry from
FfiSession::sync_pull is passed through unchanged.
Fields§
§album_id: Vec<u8>The album the feed claims this entry belongs to — 16 raw UUID bytes. Cross-checked against the manifest by the chokepoint itself, never trusted on its own.
manifest_cbor: Vec<u8>The signed AssetManifest as opaque canonical CBOR, carried verbatim.
metadata_blob: Vec<u8>The sealed metadata blob the manifest commits to.
original_ciphertext: Vec<u8>The asset’s original ciphertext. Required: the chokepoint’s content-integrity step hashes it against the manifest’s declared content address, and there is no variant of that check which skips it — so fetch the original blob before applying.
It crosses whole, so this record costs the original’s full size in memory. An original
of any size is received with
FfiSession::fetch_blob_to_path, and
applied and opened from that file with an FfiSyncHead through
FfiWorkspace::apply_sync_entry_from_file and FfiWorkspace::open_synced_original,
in bounded memory.
local_chain_head: Option<Vec<u8>>The 32-byte provenance head your catalog already holds for this asset, or None if it
has never seen it. This is what decides replay and fork; feed back
FfiAssetFacts::provenance_head after a successful apply.
Trait Implementations§
Source§impl<UT> ConvertError<UT> for FfiSyncEntry
impl<UT> ConvertError<UT> for FfiSyncEntry
fn try_convert_unexpected_callback_error( e: UnexpectedUniFFICallbackError, ) -> Result<Self>
Source§impl Debug for FfiSyncEntry
impl Debug for FfiSyncEntry
Source§impl<UT> FfiConverter<UT> for FfiSyncEntry
impl<UT> FfiConverter<UT> for FfiSyncEntry
Source§const TYPE_ID_META: MetadataBuffer
const TYPE_ID_META: MetadataBuffer
Source§type FfiType = RustBuffer
type FfiType = RustBuffer
Source§fn lower(v: Self) -> RustBuffer
fn lower(v: Self) -> RustBuffer
Source§fn try_lift(buf: RustBuffer) -> Result<Self>
fn try_lift(buf: RustBuffer) -> Result<Self>
Source§impl<UT> Lift<UT> for FfiSyncEntry
impl<UT> Lift<UT> for FfiSyncEntry
Source§impl<UT> LiftRef<UT> for FfiSyncEntry
impl<UT> LiftRef<UT> for FfiSyncEntry
type LiftType = FfiSyncEntry
Source§impl<UT> LiftReturn<UT> for FfiSyncEntry
impl<UT> LiftReturn<UT> for FfiSyncEntry
Source§type ReturnType = <FfiSyncEntry as Lift<UT>>::FfiType
type ReturnType = <FfiSyncEntry as Lift<UT>>::FfiType
Source§fn try_lift_successful_return(v: Self::ReturnType) -> Result<Self>
fn try_lift_successful_return(v: Self::ReturnType) -> Result<Self>
§fn lift_foreign_return(
ffi_return: Self::ReturnType,
call_status: RustCallStatus,
) -> Self
fn lift_foreign_return( ffi_return: Self::ReturnType, call_status: RustCallStatus, ) -> Self
§fn lift_error(_buf: RustBuffer) -> Self
fn lift_error(_buf: RustBuffer) -> Self
§fn handle_callback_unexpected_error(e: UnexpectedUniFFICallbackError) -> Self
fn handle_callback_unexpected_error(e: UnexpectedUniFFICallbackError) -> Self
Source§impl<UT> Lower<UT> for FfiSyncEntry
impl<UT> Lower<UT> for FfiSyncEntry
Source§impl<UT> LowerError<UT> for FfiSyncEntry
impl<UT> LowerError<UT> for FfiSyncEntry
Source§fn lower_error(obj: Self) -> RustBuffer
fn lower_error(obj: Self) -> RustBuffer
Source§impl<UT> LowerReturn<UT> for FfiSyncEntry
impl<UT> LowerReturn<UT> for FfiSyncEntry
Source§type ReturnType = <FfiSyncEntry as Lower<UT>>::FfiType
type ReturnType = <FfiSyncEntry as Lower<UT>>::FfiType
Source§fn lower_return(v: Self) -> Result<Self::ReturnType, RustCallError>
fn lower_return(v: Self) -> Result<Self::ReturnType, RustCallError>
§fn handle_failed_lift(
error: LiftArgsError,
) -> Result<Self::ReturnType, RustCallError>
fn handle_failed_lift( error: LiftArgsError, ) -> Result<Self::ReturnType, RustCallError>
Source§impl<UT> TypeId<UT> for FfiSyncEntry
impl<UT> TypeId<UT> for FfiSyncEntry
const TYPE_ID_META: MetadataBuffer
Auto Trait Implementations§
impl Freeze for FfiSyncEntry
impl RefUnwindSafe for FfiSyncEntry
impl Send for FfiSyncEntry
impl Sync for FfiSyncEntry
impl Unpin for FfiSyncEntry
impl UnsafeUnpin for FfiSyncEntry
impl UnwindSafe for FfiSyncEntry
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> CompatExt for T
impl<T> CompatExt for T
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
§unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
Arc<> Read more§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