pub struct FailureContextCollector;Expand description
Collector for failure context
Implementations§
Source§impl FailureContextCollector
impl FailureContextCollector
Sourcepub fn collect_context(
&self,
method: &str,
path: &str,
status_code: Option<u16>,
error_message: Option<String>,
) -> Result<FailureContext>
pub fn collect_context( &self, method: &str, path: &str, status_code: Option<u16>, error_message: Option<String>, ) -> Result<FailureContext>
Collect failure context from request execution details.
This method builds a normalized context object from the provided request/response inputs with safe defaults for optional integrations.
Sourcepub fn collect_context_with_details(
&self,
method: &str,
path: &str,
headers: HashMap<String, String>,
query_params: HashMap<String, String>,
body: Option<Value>,
status_code: Option<u16>,
response_headers: HashMap<String, String>,
response_body: Option<Value>,
duration_ms: Option<u64>,
error_message: Option<String>,
chaos_configs: Vec<ChaosConfigInfo>,
consistency_rules: Vec<ConsistencyRuleInfo>,
contract_validation: Option<ContractValidationInfo>,
behavioral_rules: Vec<BehavioralRuleInfo>,
hook_results: Vec<HookExecutionInfo>,
) -> Result<FailureContext>
pub fn collect_context_with_details( &self, method: &str, path: &str, headers: HashMap<String, String>, query_params: HashMap<String, String>, body: Option<Value>, status_code: Option<u16>, response_headers: HashMap<String, String>, response_body: Option<Value>, duration_ms: Option<u64>, error_message: Option<String>, chaos_configs: Vec<ChaosConfigInfo>, consistency_rules: Vec<ConsistencyRuleInfo>, contract_validation: Option<ContractValidationInfo>, behavioral_rules: Vec<BehavioralRuleInfo>, hook_results: Vec<HookExecutionInfo>, ) -> Result<FailureContext>
Collect context with additional details
Trait Implementations§
Source§impl Debug for FailureContextCollector
impl Debug for FailureContextCollector
Auto Trait Implementations§
impl Freeze for FailureContextCollector
impl RefUnwindSafe for FailureContextCollector
impl Send for FailureContextCollector
impl Sync for FailureContextCollector
impl Unpin for FailureContextCollector
impl UnsafeUnpin for FailureContextCollector
impl UnwindSafe for FailureContextCollector
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