pub struct NautilusAgent { /* private fields */ }Expand description
SSH & rsync file-transfer bridge agent.
Implementations§
Source§impl NautilusAgent
impl NautilusAgent
Sourcepub fn new(config: ActorConfig) -> Self
pub fn new(config: ActorConfig) -> Self
Create a new NautilusAgent with the given actor config.
Sourcepub fn with_nautilus_config(
config: ActorConfig,
nautilus: NautilusConfig,
) -> Self
pub fn with_nautilus_config( config: ActorConfig, nautilus: NautilusConfig, ) -> Self
Create a new NautilusAgent with custom SSH/rsync configuration.
Sourcepub fn with_publisher(self, p: EventPublisher) -> Self
pub fn with_publisher(self, p: EventPublisher) -> Self
Attach an EventPublisher for MQTT output.
Trait Implementations§
Source§impl Actor for NautilusAgent
impl Actor for NautilusAgent
Source§fn state(&self) -> ActorState
fn state(&self) -> ActorState
Return the current lifecycle state.
Source§fn metrics(&self) -> Arc<ActorMetrics>
fn metrics(&self) -> Arc<ActorMetrics>
Return a reference to this actor’s metrics.
Source§fn is_protected(&self) -> bool
fn is_protected(&self) -> bool
Return whether this actor is protected from external kill commands.
Source§fn on_start<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_start<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called once after the actor is created, before the message loop starts.
Source§fn handle_message<'life0, 'async_trait>(
&'life0 mut self,
message: Message,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_message<'life0, 'async_trait>(
&'life0 mut self,
message: Message,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called with each incoming message from the mailbox.
Source§fn on_heartbeat<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_heartbeat<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called on heartbeat tick; default implementation is a no-op.
Auto Trait Implementations§
impl Freeze for NautilusAgent
impl RefUnwindSafe for NautilusAgent
impl Send for NautilusAgent
impl Sync for NautilusAgent
impl Unpin for NautilusAgent
impl UnwindSafe for NautilusAgent
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