pub enum PollerResult<M, F = JsonFormat>where
M: StatusMonitor,
F: Format,{
InProgress {
response: Response<M, F>,
retry_after: Duration,
continuation: PollerContinuation,
},
Done {
response: Response<M, F>,
},
Succeeded {
response: Response<M, F>,
target: Box<dyn FnOnce() -> Pin<Box<dyn Future<Output = Result<Response<<M as StatusMonitor>::Output, <M as StatusMonitor>::Format>>> + Send>> + Send>,
},
}Expand description
The result of fetching the status monitor from a Poller, whether the long-running operation (LRO) is in progress or done.
Variants§
InProgress
The long-running operation (LRO) is in progress and the next status monitor update may be fetched from continuation.
§Fields
responsecontains the HTTP response with the status monitor.retry_afteris the optional client-specifiedDurationto wait. The default is 30 seconds.continuationis the next link / continuation token.
Fields
§
continuation: PollerContinuationThe next link / continuation token.
Done
The long-running operation (LRO) succeeded and contains the final output.
§Fields
responsecontains the HTTP response with the status monitor in a terminal state.
Succeeded
The long-running operation (LRO) succeeded and contains the final status.
§Fields
responsecontains the HTTP response with the final status monitor.get_targetis an async function that fetches the final output.
Trait Implementations§
Auto Trait Implementations§
impl<M, F = JsonFormat> !Freeze for PollerResult<M, F>
impl<M, F = JsonFormat> !RefUnwindSafe for PollerResult<M, F>
impl<M, F = JsonFormat> !Sync for PollerResult<M, F>
impl<M, F = JsonFormat> !UnwindSafe for PollerResult<M, F>
impl<M, F> Send for PollerResult<M, F>
impl<M, F> Unpin for PollerResult<M, F>
impl<M, F> UnsafeUnpin for PollerResult<M, F>where
Response<M, F>: UnsafeUnpin,
Box<dyn FnOnce() -> Pin<Box<dyn Future<Output = Result<Response<<M as StatusMonitor>::Output, <M as StatusMonitor>::Format>, Error>> + Send>> + Send>: UnsafeUnpin,
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> 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> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ServiceExt for T
impl<T> ServiceExt for T
Source§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
Source§fn decompression(self) -> Decompression<Self>where
Self: Sized,
fn decompression(self) -> Decompression<Self>where
Self: Sized,
Decompress response bodies. Read more
Source§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
Source§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more