pub struct LifecycleHandler {
pub exec: Option<ExecAction>,
pub http_get: Option<HTTPGetAction>,
pub sleep: Option<SleepAction>,
pub tcp_socket: Option<TCPSocketAction>,
}
Expand description
LifecycleHandler defines a specific action that should be taken in a lifecycle hook. One and only one of the fields, except TCPSocket must be specified.
Fields§
§exec: Option<ExecAction>
Exec specifies a command to execute in the container.
http_get: Option<HTTPGetAction>
HTTPGet specifies an HTTP GET request to perform.
sleep: Option<SleepAction>
Sleep represents a duration that the container should sleep.
tcp_socket: Option<TCPSocketAction>
Deprecated. TCPSocket is NOT supported as a LifecycleHandler and kept for backward compatibility. There is no validation of this field and lifecycle hooks will fail at runtime when it is specified.
Trait Implementations§
Source§impl Clone for LifecycleHandler
impl Clone for LifecycleHandler
Source§fn clone(&self) -> LifecycleHandler
fn clone(&self) -> LifecycleHandler
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for LifecycleHandler
impl Debug for LifecycleHandler
Source§impl DeepMerge for LifecycleHandler
impl DeepMerge for LifecycleHandler
Source§fn merge_from(&mut self, other: Self)
fn merge_from(&mut self, other: Self)
Merge
other
into self
.Source§impl Default for LifecycleHandler
impl Default for LifecycleHandler
Source§fn default() -> LifecycleHandler
fn default() -> LifecycleHandler
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for LifecycleHandler
impl<'de> Deserialize<'de> for LifecycleHandler
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for LifecycleHandler
impl PartialEq for LifecycleHandler
Source§impl Serialize for LifecycleHandler
impl Serialize for LifecycleHandler
impl StructuralPartialEq for LifecycleHandler
Auto Trait Implementations§
impl Freeze for LifecycleHandler
impl RefUnwindSafe for LifecycleHandler
impl Send for LifecycleHandler
impl Sync for LifecycleHandler
impl Unpin for LifecycleHandler
impl UnwindSafe for LifecycleHandler
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