pub struct RemoteSystem {
pub system: ActorSystem,
pub provider: Arc<RemoteActorRefProvider>,
pub daemon: Arc<RemoteSystemDaemon>,
pub watcher: Arc<RemoteWatcher>,
pub address_uid: AddressUid,
pub local_address: Address,
}Expand description
Returned by RemoteSystem::start.
Fields§
§system: ActorSystem§provider: Arc<RemoteActorRefProvider>§daemon: Arc<RemoteSystemDaemon>§watcher: Arc<RemoteWatcher>§address_uid: AddressUid§local_address: AddressImplementations§
Source§impl RemoteSystem
impl RemoteSystem
Sourcepub async fn start(
system: ActorSystem,
bind: SocketAddr,
settings: RemoteSettings,
) -> Result<Self, TransportError>
pub async fn start( system: ActorSystem, bind: SocketAddr, settings: RemoteSettings, ) -> Result<Self, TransportError>
Convenience: build a TcpTransport bound to bind, install it on
system, and return the wired RemoteSystem.
pub async fn start_with_transport( system: ActorSystem, transport: Arc<dyn Transport>, settings: RemoteSettings, ) -> Result<Self, TransportError>
pub fn endpoint_manager(&self) -> &EndpointManager
pub fn registry(&self) -> &SerializerRegistry
Sourcepub fn register_bincode<T>(&self)
pub fn register_bincode<T>(&self)
Register the bincode codec for T. Required for any user message
type that crosses the wire.
Sourcepub fn register_json<T>(&self)
pub fn register_json<T>(&self)
Register the JSON codec for T.
Sourcepub fn expose_actor<M>(&self, target: ActorRef<M>)where
M: Send + 'static,
pub fn expose_actor<M>(&self, target: ActorRef<M>)where
M: Send + 'static,
Register a local actor as the destination for inbound remote
messages addressed to its path. Caller must already have the
codec for M registered.
Sourcepub fn actor_selection<M>(&self, path: &str) -> Option<ActorRef<M>>
pub fn actor_selection<M>(&self, path: &str) -> Option<ActorRef<M>>
Look up a remote actor by full path string, returning a typed
ActorRef<M> with the bincode codec for M. Caller is responsible
for matching M to whatever the receiving side declares.
Sourcepub fn actor_selection_untyped(&self, path: &str) -> Option<UntypedActorRef>
pub fn actor_selection_untyped(&self, path: &str) -> Option<UntypedActorRef>
Untyped variant — useful for system-message-only refs (e.g. remote watchers).
pub async fn shutdown(&self)
Auto Trait Implementations§
impl Freeze for RemoteSystem
impl !RefUnwindSafe for RemoteSystem
impl Send for RemoteSystem
impl Sync for RemoteSystem
impl Unpin for RemoteSystem
impl UnsafeUnpin for RemoteSystem
impl !UnwindSafe for RemoteSystem
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