pub struct ExecutionJson {
pub target: TargetEcho,
pub active_fallback: bool,
pub stdout: String,
pub stderr: String,
pub exit_code: Option<i32>,
pub truncated_stdout: bool,
pub truncated_stderr: bool,
pub duration_ms: u64,
}Expand description
exec / sudo-exec / su-exec JSON stdout.
Fields§
§target: TargetEchoCanonical target fields plus their host_* read aliases.
active_fallback: boolWhether the host was inherited from the active marker instead of argv.
Redundant with TargetEcho::target_source on purpose: a boolean gate is what
a shell pipeline can branch on without knowing the enum spelling.
stdout: StringCaptured remote stdout.
stderr: StringCaptured remote stderr.
exit_code: Option<i32>Remote exit code when available.
truncated_stdout: boolWhether stdout was truncated by max_output_chars.
truncated_stderr: boolWhether stderr was truncated by max_output_chars.
duration_ms: u64Wall-clock duration in milliseconds.
Implementations§
Source§impl ExecutionJson
impl ExecutionJson
Sourcepub fn with_target(o: &ExecutionOutput, target: &ExecTarget) -> Self
pub fn with_target(o: &ExecutionOutput, target: &ExecTarget) -> Self
Builds the envelope with the target identity attached.
The only constructor, deliberately. A From<&ExecutionOutput> conversion used
to exist and filled the audit fields with empty values, because an
ExecutionOutput knows what happened and not where. Removing it makes an
envelope that disclaims its own target unrepresentable.
Trait Implementations§
Source§impl Clone for ExecutionJson
impl Clone for ExecutionJson
Source§fn clone(&self) -> ExecutionJson
fn clone(&self) -> ExecutionJson
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ExecutionJson
impl Debug for ExecutionJson
Source§impl<'de> Deserialize<'de> for ExecutionJson
impl<'de> Deserialize<'de> for ExecutionJson
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>,
impl Eq for ExecutionJson
Source§impl PartialEq for ExecutionJson
impl PartialEq for ExecutionJson
Source§impl Serialize for ExecutionJson
impl Serialize for ExecutionJson
impl StructuralPartialEq for ExecutionJson
Auto Trait Implementations§
impl Freeze for ExecutionJson
impl RefUnwindSafe for ExecutionJson
impl Send for ExecutionJson
impl Sync for ExecutionJson
impl Unpin for ExecutionJson
impl UnsafeUnpin for ExecutionJson
impl UnwindSafe for ExecutionJson
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.