pub struct RunFunctionResponse {
pub meta: Option<ResponseMeta>,
pub desired: Option<State>,
pub results: Vec<Result>,
pub context: Option<Struct>,
pub requirements: Option<Requirements>,
pub conditions: Vec<Condition>,
pub output: Option<Struct>,
}Expand description
A RunFunctionResponse contains the result of a function run.
Fields§
§meta: Option<ResponseMeta>Metadata pertaining to this response.
desired: Option<State>Desired state according to a function pipeline. functions may add desired state, and may mutate or delete any part of the desired state they are concerned with. A function must pass through any part of the desired state that it is not concerned with.
Note that the desired state must be a partial object with only the fields that this function (and its predecessors in the pipeline) wants to have set in the object. Copying a non-partial observed state to desired is most likely not what you want to do. Leaving out fields that had been returned as desired before will result in them being deleted from the objects in the cluster.
results: Vec<Result>Results of the function run. Results are used for observability purposes.
context: Option<Struct>Optional context to be passed to the next function in the pipeline as part of the RunFunctionRequest. Dropped on the last function in the pipeline.
requirements: Option<Requirements>Requirements that must be satisfied for this function to run successfully.
conditions: Vec<Condition>Status conditions to be applied to the XR. Conditions may also optionally be applied to the XR’s associated claim.
Conditions are only used for composition. They’re ignored by Operations.
output: Option<Struct>Optional output specific to this function invocation.
Only Operations use function output. XRs will discard any function output.
Trait Implementations§
Source§impl Clone for RunFunctionResponse
impl Clone for RunFunctionResponse
Source§impl Debug for RunFunctionResponse
impl Debug for RunFunctionResponse
Source§impl Default for RunFunctionResponse
impl Default for RunFunctionResponse
§impl<'de> Deserialize<'de> for RunFunctionResponse
impl<'de> Deserialize<'de> for RunFunctionResponse
§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>,
Source§impl Message for RunFunctionResponse
impl Message for RunFunctionResponse
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl PartialEq for RunFunctionResponse
impl PartialEq for RunFunctionResponse
§impl Serialize for RunFunctionResponse
impl Serialize for RunFunctionResponse
impl StructuralPartialEq for RunFunctionResponse
Auto Trait Implementations§
impl Freeze for RunFunctionResponse
impl RefUnwindSafe for RunFunctionResponse
impl Send for RunFunctionResponse
impl Sync for RunFunctionResponse
impl Unpin for RunFunctionResponse
impl UnsafeUnpin for RunFunctionResponse
impl UnwindSafe for RunFunctionResponse
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<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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request