pub struct Receipt {
pub id: ReceiptId,
pub flow_run_id: FlowRunId,
pub node_id: NodeId,
pub step_run_id: StepRunId,
pub connector: String,
pub timestamp: DateTime<Utc>,
pub attempt_id_raw: Uuid,
pub input_hash: String,
pub output_hash: Option<String>,
pub status: ReceiptStatus,
pub error: Option<String>,
pub duration_ms: u64,
}Expand description
Immutable evidence of a single boundary crossing.
Fields§
§id: ReceiptIdContent-addressed ID (SHA-256 hash of all other fields).
flow_run_id: FlowRunIdWhich flow run this crossing belongs to.
node_id: NodeIdWhich node performed the crossing.
step_run_id: StepRunIdThe step execution that performed the crossing.
connector: StringName of the connector that was invoked.
timestamp: DateTime<Utc>When the crossing occurred.
attempt_id_raw: UuidThe ActionQueue AttemptId (stored as raw UUID to avoid AQ dependency).
input_hash: StringSHA-256 hex digest of the serialized input parameters.
output_hash: Option<String>SHA-256 hex digest of the output. None if the crossing failed.
status: ReceiptStatusWhether the crossing succeeded, failed, or timed out.
error: Option<String>Error message, present when status is Failure or Timeout.
duration_ms: u64Wall-clock duration of the connector invocation in milliseconds.
Implementations§
Source§impl Receipt
impl Receipt
Sourcepub fn new(
flow_run_id: FlowRunId,
node_id: NodeId,
step_run_id: StepRunId,
connector: String,
timestamp: DateTime<Utc>,
attempt_id_raw: Uuid,
input_hash: String,
output_hash: Option<String>,
status: ReceiptStatus,
error: Option<String>,
duration_ms: u64,
) -> Self
pub fn new( flow_run_id: FlowRunId, node_id: NodeId, step_run_id: StepRunId, connector: String, timestamp: DateTime<Utc>, attempt_id_raw: Uuid, input_hash: String, output_hash: Option<String>, status: ReceiptStatus, error: Option<String>, duration_ms: u64, ) -> Self
Construct a new receipt. The content-addressed ID is computed automatically from all fields.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Receipt
impl<'de> Deserialize<'de> for Receipt
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
impl StructuralPartialEq for Receipt
Auto Trait Implementations§
impl Freeze for Receipt
impl RefUnwindSafe for Receipt
impl Send for Receipt
impl Sync for Receipt
impl Unpin for Receipt
impl UnsafeUnpin for Receipt
impl UnwindSafe for Receipt
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