pub struct JournalEffector {}
journal
only.Expand description
The journal effector is an adapter that will be removed in a future refactor. Its purpose is to put the code that does mappings from WASM memory through its abstractions into concrete journal objects that can be stored. Instead of this what should be done is that the syscalls themselves can be represented as a strongly typed object that can be passed directly to the journal but in order to do this we require an extensive refactoring of the WASIX syscalls which is not in scope at this time.
Separating this out now makes it easier to eliminate later without hurting the journal event abstraction through leaking abstraction layers.
Implementations§
Source§impl JournalEffector
impl JournalEffector
pub fn save_chdir( ctx: &mut FunctionEnvMut<'_, WasiEnv>, path: String, ) -> Result<()>
pub fn apply_chdir( ctx: &mut FunctionEnvMut<'_, WasiEnv>, path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_clock_time_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, clock_id: Snapshot0Clockid, time: Timestamp, ) -> Result<()>
pub fn apply_clock_time_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, clock_id: Snapshot0Clockid, time: Timestamp, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_epoll_create( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ) -> Result<()>
pub fn apply_epoll_create( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_epoll_ctl( ctx: &mut FunctionEnvMut<'_, WasiEnv>, epfd: Fd, op: EpollCtl, fd: Fd, event: Option<EpollEventCtl>, ) -> Result<()>
pub fn apply_epoll_ctl( ctx: &mut FunctionEnvMut<'_, WasiEnv>, pfd: Fd, op: EpollCtl, fd: Fd, event: Option<EpollEventCtl>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_advise( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: Filesize, len: Filesize, advice: Advice, ) -> Result<()>
pub fn apply_fd_advise( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: Filesize, len: Filesize, advice: Advice, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_allocate( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: Filesize, len: Filesize, ) -> Result<()>
pub fn apply_fd_allocate( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: Filesize, len: Filesize, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_close( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ) -> Result<()>
pub fn apply_fd_close( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_duplicate( ctx: &mut FunctionEnvMut<'_, WasiEnv>, original_fd: Fd, copied_fd: Fd, ) -> Result<()>
pub fn apply_fd_duplicate( ctx: &mut FunctionEnvMut<'_, WasiEnv>, original_fd: Fd, copied_fd: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_event( ctx: &mut FunctionEnvMut<'_, WasiEnv>, initial_val: u64, flags: EventFdFlags, fd: Fd, ) -> Result<()>
pub fn apply_fd_event( ctx: &mut FunctionEnvMut<'_, WasiEnv>, initial_val: u64, flags: EventFdFlags, fd: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_pipe( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd1: Fd, fd2: Fd, ) -> Result<()>
pub fn apply_fd_pipe( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd1: Fd, fd2: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_renumber( ctx: &mut FunctionEnvMut<'_, WasiEnv>, from: Fd, to: Fd, ) -> Result<()>
pub fn apply_fd_renumber( ctx: &mut FunctionEnvMut<'_, WasiEnv>, from: Fd, to: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_seek( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: i64, whence: Whence, ) -> Result<()>
pub fn apply_fd_seek( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: i64, whence: Whence, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_set_flags( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, flags: Fdflags, ) -> Result<()>
pub fn apply_fd_set_flags( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, flags: Fdflags, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_set_rights( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, fs_rights_base: Rights, fs_rights_inheriting: Rights, ) -> Result<()>
pub fn apply_fd_set_rights( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, fs_rights_base: Rights, fs_rights_inheriting: Rights, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_set_size( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, st_size: Filesize, ) -> Result<()>
pub fn apply_fd_set_size( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, st_size: Filesize, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_set_times( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, st_atim: Timestamp, st_mtim: Timestamp, fst_flags: Fstflags, ) -> Result<()>
pub fn apply_fd_set_times( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, st_atim: Timestamp, st_mtim: Timestamp, fst_flags: Fstflags, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_fd_write<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: u64, written: usize, iovs: WasmPtr<__wasi_ciovec_t<M>, M>, iovs_len: M::Offset, ) -> Result<()>
pub fn apply_fd_write<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, fd: Fd, offset: u64, data: Cow<'_, [u8]>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_create_directory( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: String, ) -> Result<()>
pub fn apply_path_create_directory( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_link( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_fd: Fd, old_flags: LookupFlags, old_path: String, new_fd: Fd, new_path: String, ) -> Result<()>
pub fn apply_path_link( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_fd: Fd, old_flags: LookupFlags, old_path: &str, new_fd: Fd, new_path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_open( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, dirfd: Fd, dirflags: LookupFlags, path: String, o_flags: Oflags, fs_rights_base: Rights, fs_rights_inheriting: Rights, fs_flags: Fdflags, ) -> Result<()>
pub fn apply_path_open( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, dirfd: Fd, dirflags: LookupFlags, path: &str, o_flags: Oflags, fs_rights_base: Rights, fs_rights_inheriting: Rights, fs_flags: Fdflags, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_remove_directory( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: String, ) -> Result<()>
pub fn apply_path_remove_directory( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_rename( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_fd: Fd, old_path: String, new_fd: Fd, new_path: String, ) -> Result<()>
pub fn apply_path_rename( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_fd: Fd, old_path: &str, new_fd: Fd, new_path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_set_times( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, flags: LookupFlags, path: String, st_atim: Timestamp, st_mtim: Timestamp, fst_flags: Fstflags, ) -> Result<()>
pub fn apply_path_set_times( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, flags: LookupFlags, path: &str, st_atim: Timestamp, st_mtim: Timestamp, fst_flags: Fstflags, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_symlink( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_path: String, fd: Fd, new_path: String, ) -> Result<()>
pub fn apply_path_symlink( ctx: &mut FunctionEnvMut<'_, WasiEnv>, old_path: &str, fd: Fd, new_path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_path_unlink( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: String, ) -> Result<()>
pub fn apply_path_unlink( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, path: &str, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_addr_add( ctx: &mut FunctionEnvMut<'_, WasiEnv>, cidr: IpCidr, ) -> Result<()>
pub fn apply_port_addr_add( ctx: &mut FunctionEnvMut<'_, WasiEnv>, cidr: IpCidr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_addr_clear(ctx: &mut FunctionEnvMut<'_, WasiEnv>) -> Result<()>
pub fn apply_port_addr_clear( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_addr_remove( ctx: &mut FunctionEnvMut<'_, WasiEnv>, addr: IpAddr, ) -> Result<()>
pub fn apply_port_addr_remove( ctx: &mut FunctionEnvMut<'_, WasiEnv>, addr: IpAddr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_bridge( ctx: &mut FunctionEnvMut<'_, WasiEnv>, network: String, token: String, security: StreamSecurity, ) -> Result<()>
pub fn apply_port_bridge( ctx: &mut FunctionEnvMut<'_, WasiEnv>, network: &str, token: &str, security: StreamSecurity, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_dhcp_acquire( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ) -> Result<()>
pub fn apply_port_dhcp_acquire( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_gateway_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ip: IpAddr, ) -> Result<()>
pub fn apply_port_gateway_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ip: IpAddr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_route_add( ctx: &mut FunctionEnvMut<'_, WasiEnv>, cidr: IpCidr, via_router: IpAddr, preferred_until: Option<Duration>, expires_at: Option<Duration>, ) -> Result<()>
pub fn apply_port_route_add( ctx: &mut FunctionEnvMut<'_, WasiEnv>, cidr: IpCidr, via_router: IpAddr, preferred_until: Option<Duration>, expires_at: Option<Duration>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_route_clear( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ) -> Result<()>
pub fn apply_port_route_clear( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_route_remove( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ip: IpAddr, ) -> Result<()>
pub fn apply_port_route_remove( ctx: &mut FunctionEnvMut<'_, WasiEnv>, ip: IpAddr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_port_unbridge(ctx: &mut FunctionEnvMut<'_, WasiEnv>) -> Result<()>
pub fn apply_port_unbridge(ctx: &mut FunctionEnvMut<'_, WasiEnv>) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_accepted( ctx: &mut FunctionEnvMut<'_, WasiEnv>, listen_fd: Fd, fd: Fd, addr: SocketAddr, peer_addr: SocketAddr, fd_flags: Fdflags, nonblocking: bool, ) -> Result<()>
pub fn apply_sock_accepted( ctx: &mut FunctionEnvMut<'_, WasiEnv>, _listen_fd: Fd, fd: Fd, addr: SocketAddr, peer_addr: SocketAddr, fd_flags: Fdflags, nonblocking: bool, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_bind( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, addr: SocketAddr, ) -> Result<()>
pub fn apply_sock_bind( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, addr: SocketAddr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_connect( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, local_addr: SocketAddr, peer_addr: SocketAddr, ) -> Result<()>
pub fn apply_sock_connect( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, local_addr: SocketAddr, peer_addr: SocketAddr, dead: bool, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_join_ipv4_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv4Addr, iface: Ipv4Addr, ) -> Result<()>
pub fn apply_sock_join_ipv4_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv4Addr, iface: Ipv4Addr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_join_ipv6_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv6Addr, iface: u32, ) -> Result<()>
pub fn apply_sock_join_ipv6_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv6Addr, iface: u32, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_leave_ipv4_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv4Addr, iface: Ipv4Addr, ) -> Result<()>
pub fn apply_sock_leave_ipv4_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv4Addr, iface: Ipv4Addr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_leave_ipv6_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv6Addr, iface: u32, ) -> Result<()>
pub fn apply_sock_leave_ipv6_multicast( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, multiaddr: Ipv6Addr, iface: u32, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_listen( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, backlog: usize, ) -> Result<()>
pub fn apply_sock_listen( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, backlog: usize, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_open( ctx: &mut FunctionEnvMut<'_, WasiEnv>, af: Addressfamily, ty: Socktype, pt: SockProto, fd: Fd, ) -> Result<()>
pub fn apply_sock_open( ctx: &mut FunctionEnvMut<'_, WasiEnv>, af: Addressfamily, ty: Socktype, pt: SockProto, fd: Fd, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_send<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, fd: Fd, sent: usize, iovs: WasmPtr<__wasi_ciovec_t<M>, M>, iovs_len: M::Offset, si_flags: SiFlags, ) -> Result<()>
pub fn apply_sock_send<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, sock: Fd, si_data: Cow<'_, [u8]>, si_flags: SiFlags, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_send_file<M: MemorySize>( ctx: &mut FunctionEnvMut<'_, WasiEnv>, socket_fd: Fd, file_fd: Fd, offset: Filesize, count: Filesize, ) -> Result<()>
pub fn apply_sock_send_file( ctx: &mut FunctionEnvMut<'_, WasiEnv>, socket_fd: Fd, file_fd: Fd, offset: Filesize, count: Filesize, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_send_to<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, fd: Fd, sent: usize, iovs: WasmPtr<__wasi_ciovec_t<M>, M>, iovs_len: M::Offset, addr: SocketAddr, si_flags: SiFlags, ) -> Result<()>
pub fn apply_sock_send_to<M: MemorySize>( ctx: &FunctionEnvMut<'_, WasiEnv>, sock: Fd, si_data: Cow<'_, [u8]>, si_flags: SiFlags, addr: SocketAddr, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_set_opt_flag( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, opt: Sockoption, flag: bool, ) -> Result<()>
pub fn apply_sock_set_opt_flag( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, opt: Sockoption, flag: bool, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_set_opt_size( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, opt: Sockoption, size: Filesize, ) -> Result<()>
pub fn apply_sock_set_opt_size( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, opt: Sockoption, size: Filesize, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_set_opt_time( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ty: TimeType, time: Option<Duration>, ) -> Result<()>
pub fn apply_sock_set_opt_time( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, ty: TimeType, time: Option<Duration>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_sock_shutdown( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, shutdown: Shutdown, ) -> Result<()>
pub fn apply_sock_shutdown( ctx: &mut FunctionEnvMut<'_, WasiEnv>, fd: Fd, shutdown: Shutdown, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_tty_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, state: WasiTtyState, ) -> Result<()>
pub fn apply_tty_set( ctx: &mut FunctionEnvMut<'_, WasiEnv>, state: WasiTtyState, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_memory_and_snapshot( ctx: &mut FunctionEnvMut<'_, WasiEnv>, guard: &mut MutexGuard<'_, WasiProcessInner>, trigger: SnapshotTrigger, ) -> Result<()>
Sourcepub unsafe fn apply_compressed_memory(
ctx: &mut FunctionEnvMut<'_, WasiEnv>,
region: Range<u64>,
compressed_data: &[u8],
) -> Result<()>
pub unsafe fn apply_compressed_memory( ctx: &mut FunctionEnvMut<'_, WasiEnv>, region: Range<u64>, compressed_data: &[u8], ) -> Result<()>
§Safety
This function manipulates the memory of the process and thus must be executed by the WASM process thread itself.
Source§impl JournalEffector
impl JournalEffector
pub fn save_process_exit( env: &WasiEnv, exit_code: Option<ExitCode>, ) -> Result<()>
Sourcepub unsafe fn apply_process_exit(
ctx: &mut FunctionEnvMut<'_, WasiEnv>,
exit_code: Option<ExitCode>,
) -> Result<()>
pub unsafe fn apply_process_exit( ctx: &mut FunctionEnvMut<'_, WasiEnv>, exit_code: Option<ExitCode>, ) -> Result<()>
§Safety
This function manipulates the memory of the process and thus must be executed by the WASM process thread itself.
Source§impl JournalEffector
impl JournalEffector
pub fn save_thread_exit( env: &WasiEnv, id: WasiThreadId, exit_code: Option<ExitCode>, ) -> Result<()>
pub fn apply_thread_exit( ctx: &mut FunctionEnvMut<'_, WasiEnv>, tid: WasiThreadId, exit_code: Option<ExitCode>, ) -> Result<()>
Source§impl JournalEffector
impl JournalEffector
pub fn save_thread_state<M: MemorySize>( ctx: &mut FunctionEnvMut<'_, WasiEnv>, id: WasiThreadId, memory_stack: Bytes, rewind_stack: Bytes, store_data: Bytes, start: ThreadStartType, layout: WasiMemoryLayout, ) -> Result<()>
Sourcepub fn apply_thread_state<M: MemorySize>(
ctx: &mut FunctionEnvMut<'_, WasiEnv>,
tid: WasiThreadId,
memory_stack: Bytes,
rewind_stack: Bytes,
store_data: Bytes,
start: ThreadStartType,
layout: WasiMemoryLayout,
) -> Result<()>
pub fn apply_thread_state<M: MemorySize>( ctx: &mut FunctionEnvMut<'_, WasiEnv>, tid: WasiThreadId, memory_stack: Bytes, rewind_stack: Bytes, store_data: Bytes, start: ThreadStartType, layout: WasiMemoryLayout, ) -> Result<()>
This will take the supplied stacks and apply them to the memory region dedicated to this thread. After that it will spawn a WASM thread and
Trait Implementations§
Source§impl Clone for JournalEffector
impl Clone for JournalEffector
Source§fn clone(&self) -> JournalEffector
fn clone(&self) -> JournalEffector
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl Freeze for JournalEffector
impl RefUnwindSafe for JournalEffector
impl Send for JournalEffector
impl Sync for JournalEffector
impl Unpin for JournalEffector
impl UnwindSafe for JournalEffector
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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