pub enum PollingResult<ResponseType, MetadataType> {
InProgress(Option<MetadataType>),
Completed(Result<ResponseType, Error>),
PollingError(Error),
}Expand description
The result of polling a Long-Running Operation (LRO).
§Parameters
ResponseType- This is the type returned when the LRO completes successfully.MetadataType- The LRO may return values of this type while the operation is in progress. This may include some measure of “progress”.
Variants§
InProgress(Option<MetadataType>)
The operation is still in progress.
Completed(Result<ResponseType, Error>)
The operation completed. This includes the result.
PollingError(Error)
An error trying to poll the LRO.
Not all errors indicate that the operation failed. For example, this may fail because it was not possible to connect to Google Cloud. Such transient errors may disappear in the next polling attempt.
Other errors will never recover. For example, a ServiceError with a NOT_FOUND, ABORTED, or PERMISSION_DENIED code will never recover.
Trait Implementations§
Auto Trait Implementations§
impl<ResponseType, MetadataType> Freeze for PollingResult<ResponseType, MetadataType>
impl<ResponseType, MetadataType> !RefUnwindSafe for PollingResult<ResponseType, MetadataType>
impl<ResponseType, MetadataType> Send for PollingResult<ResponseType, MetadataType>
impl<ResponseType, MetadataType> Sync for PollingResult<ResponseType, MetadataType>
impl<ResponseType, MetadataType> Unpin for PollingResult<ResponseType, MetadataType>
impl<ResponseType, MetadataType> !UnwindSafe for PollingResult<ResponseType, MetadataType>
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