#[non_exhaustive]pub struct RazeriEvent { /* private fields */ }Expand description
Stable monitoring event envelope emitted by Razeri operations.
Implementations§
Source§impl RazeriEvent
impl RazeriEvent
Sourcepub fn new(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
subject: EventSubject,
payload: EventPayload,
) -> Result<Self, EventValidationError>
pub fn new( event_id: impl Into<String>, timestamp: DateTime<Utc>, subject: EventSubject, payload: EventPayload, ) -> Result<Self, EventValidationError>
Sourcepub fn new_with_workflow(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
subject: EventSubject,
payload: EventPayload,
) -> Result<Self, EventValidationError>
pub fn new_with_workflow( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, subject: EventSubject, payload: EventPayload, ) -> Result<Self, EventValidationError>
Sourcepub fn validate(&self) -> Result<(), EventValidationError>
pub fn validate(&self) -> Result<(), EventValidationError>
Validate that the canonical envelope is internally consistent.
§Errors
Returns an error if the operation fails.
Sourcepub fn category(&self) -> EventCategory
pub fn category(&self) -> EventCategory
Derived event category.
Sourcepub fn severity(&self) -> EventSeverity
pub fn severity(&self) -> EventSeverity
Derived event severity.
Sourcepub fn workflow(&self) -> Option<&WorkflowContext>
pub fn workflow(&self) -> Option<&WorkflowContext>
Optional workflow correlation context.
Sourcepub fn subject(&self) -> &EventSubject
pub fn subject(&self) -> &EventSubject
Primary event subject.
Sourcepub fn payload(&self) -> &EventPayload
pub fn payload(&self) -> &EventPayload
Structured event payload.
Sourcepub fn filter_keys(&self) -> EventFilterKeys
pub fn filter_keys(&self) -> EventFilterKeys
Derived filter keys suitable for summaries and operator UIs.
Sourcepub fn summary(&self) -> EventSummary
pub fn summary(&self) -> EventSummary
Human-readable summary derived from the canonical event.
Sourcepub fn design_validated(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
design: impl Into<String>,
errors: usize,
warnings: usize,
) -> Result<Self, EventValidationError>
pub fn design_validated( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, design: impl Into<String>, errors: usize, warnings: usize, ) -> Result<Self, EventValidationError>
Convenience constructor for a design validation event.
§Errors
Returns an error if the operation fails.
Sourcepub fn materialization_started(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
entity: impl Into<String>,
platform: impl Into<String>,
) -> Result<Self, EventValidationError>
pub fn materialization_started( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, entity: impl Into<String>, platform: impl Into<String>, ) -> Result<Self, EventValidationError>
Convenience constructor for a materialization-started event.
§Errors
Returns an error if the operation fails.
Sourcepub fn materialization_completed(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
entity: impl Into<String>,
platform: impl Into<String>,
artifacts: usize,
duration_ms: u64,
) -> Result<Self, EventValidationError>
pub fn materialization_completed( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, entity: impl Into<String>, platform: impl Into<String>, artifacts: usize, duration_ms: u64, ) -> Result<Self, EventValidationError>
Convenience constructor for a materialization-completed event.
§Errors
Returns an error if the operation fails.
Sourcepub fn materialization_failed(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
design: impl Into<String>,
platform: impl Into<String>,
message: impl Into<String>,
) -> Result<Self, EventValidationError>
pub fn materialization_failed( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, design: impl Into<String>, platform: impl Into<String>, message: impl Into<String>, ) -> Result<Self, EventValidationError>
Convenience constructor for a materialization-failed event.
§Errors
Returns an error if the operation fails.
Sourcepub fn profiling_started(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
source: impl Into<String>,
) -> Result<Self, EventValidationError>
pub fn profiling_started( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, source: impl Into<String>, ) -> Result<Self, EventValidationError>
Convenience constructor for a profiling-started event.
§Errors
Returns an error if the operation fails.
Sourcepub fn profiling_completed(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
source: impl Into<String>,
fields: usize,
rows: usize,
duration_ms: u64,
) -> Result<Self, EventValidationError>
pub fn profiling_completed( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, source: impl Into<String>, fields: usize, rows: usize, duration_ms: u64, ) -> Result<Self, EventValidationError>
Convenience constructor for a profiling-completed event.
§Errors
Returns an error if the operation fails.
Sourcepub fn design_loaded(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
path: impl Into<String>,
entities: usize,
) -> Result<Self, EventValidationError>
pub fn design_loaded( event_id: impl Into<String>, timestamp: DateTime<Utc>, path: impl Into<String>, entities: usize, ) -> Result<Self, EventValidationError>
Sourcepub fn plugin_loaded(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
name: impl Into<String>,
plugin_type: impl Into<String>,
source: impl Into<String>,
) -> Result<Self, EventValidationError>
pub fn plugin_loaded( event_id: impl Into<String>, timestamp: DateTime<Utc>, name: impl Into<String>, plugin_type: impl Into<String>, source: impl Into<String>, ) -> Result<Self, EventValidationError>
Sourcepub fn storage_operation_completed(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
operation: impl Into<String>,
path: impl Into<String>,
bytes: u64,
duration_ms: u64,
) -> Result<Self, EventValidationError>
pub fn storage_operation_completed( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, operation: impl Into<String>, path: impl Into<String>, bytes: u64, duration_ms: u64, ) -> Result<Self, EventValidationError>
Convenience constructor for a storage-operation-completed event.
§Errors
Returns an error if the operation fails.
Sourcepub fn llm_request_completed(
event_id: impl Into<String>,
timestamp: DateTime<Utc>,
workflow: WorkflowContext,
provider: impl Into<String>,
model: impl Into<String>,
tokens: u64,
duration_ms: u64,
) -> Result<Self, EventValidationError>
pub fn llm_request_completed( event_id: impl Into<String>, timestamp: DateTime<Utc>, workflow: WorkflowContext, provider: impl Into<String>, model: impl Into<String>, tokens: u64, duration_ms: u64, ) -> Result<Self, EventValidationError>
Convenience constructor for an LLM-request-completed event.
§Errors
Returns an error if the operation fails.
Trait Implementations§
Source§impl Clone for RazeriEvent
impl Clone for RazeriEvent
Source§impl Debug for RazeriEvent
impl Debug for RazeriEvent
Source§impl<'de> Deserialize<'de> for RazeriEvent
impl<'de> Deserialize<'de> for RazeriEvent
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 RazeriEvent
Source§impl PartialEq for RazeriEvent
impl PartialEq for RazeriEvent
Source§impl Serialize for RazeriEvent
impl Serialize for RazeriEvent
impl StructuralPartialEq for RazeriEvent
Auto Trait Implementations§
impl Forget for RazeriEvent
impl Freeze for RazeriEvent
impl Move for RazeriEvent
impl RefUnwindSafe for RazeriEvent
impl Send for RazeriEvent
impl Sync for RazeriEvent
impl Unpin for RazeriEvent
impl UnsafeUnpin for RazeriEvent
impl UnwindSafe for RazeriEvent
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.