pub struct Deployer { /* private fields */ }Expand description
Deploys one agent build on one device. Clones share the records.
Implementations§
Source§impl Deployer
impl Deployer
pub fn new(device: Device, jar: AgentJar, records: Records) -> Deployer
pub fn device(&self) -> &Device
pub fn jar(&self) -> &AgentJar
pub fn records(&self) -> &Records
Sourcepub fn state(&self) -> Result<AgentState, Error>
pub fn state(&self) -> Result<AgentState, Error>
The target’s agent state, from the process list.
Sourcepub fn attach(&self, options: &DeployOptions) -> Result<Attached, DeployError>
pub fn attach(&self, options: &DeployOptions) -> Result<Attached, DeployError>
Connects to an agent: the running one this host started when it is compatible, else a new one. Any connection the reused agent had is replaced by this one.
Sourcepub fn stop_recorded(
&self,
timeout: Duration,
) -> Result<Option<Stopped>, DeployError>
pub fn stop_recorded( &self, timeout: Duration, ) -> Result<Option<Stopped>, DeployError>
Stops the agent this host recorded for the device, when it still
runs, without a connection to it: shutdown over a new connection,
else a kill by pid. None when there was nothing to stop.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Deployer
impl RefUnwindSafe for Deployer
impl Send for Deployer
impl Sync for Deployer
impl Unpin for Deployer
impl UnsafeUnpin for Deployer
impl UnwindSafe for Deployer
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request