pub struct Running { /* private fields */ }Expand description
One server, serving.
Dropping this stops it, and so does Running::stop; nothing here outlives
the handle a caller holds.
Implementations§
Source§impl Running
impl Running
Sourcepub const fn address(&self) -> SocketAddr
pub const fn address(&self) -> SocketAddr
Where this server is answering.
Sourcepub fn ingress_url(&self) -> String
pub fn ingress_url(&self) -> String
The URL its ingress endpoint answers on.
Sourcepub const fn config(&self) -> &ServerConfig
pub const fn config(&self) -> &ServerConfig
What it was configured with.
Sourcepub const fn reconciliation(&self) -> &Reconciliation
pub const fn reconciliation(&self) -> &Reconciliation
What this start adopted from the store.
Sourcepub const fn supervisor(&self) -> &Arc<Supervisor> ⓘ
pub const fn supervisor(&self) -> &Arc<Supervisor> ⓘ
The supervision core it is serving over.
Sourcepub fn completions(&self) -> Receiver<u64>
pub fn completions(&self) -> Receiver<u64>
How many posts the ingress worker has finished handling, watchable while it works.
Sourcepub async fn serve_until_signalled(self) -> Result<(), StartError>
pub async fn serve_until_signalled(self) -> Result<(), StartError>
Serve until the operating system asks this process to stop.
This is what the server subcommand runs. It answers when the service
manager sends the signal it stops units with, or when the terminal that
started it interrupts.
§Errors
Returns StartError::State when the signal handlers cannot be
installed, which is a process that could not be stopped cleanly.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Running
impl !UnwindSafe for Running
impl Freeze for Running
impl Send for Running
impl Sync for Running
impl Unpin for Running
impl UnsafeUnpin for Running
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> ⓘ
Converts
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> ⓘ
Converts
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