pub enum ErpEventType {
ProcessInitiated,
AperakAccepted,
AperakRejected {
erc_code: Option<ErcCode>,
},
AperakTimeout,
ContrlReceived,
ProcessCompleted,
MaloIdentified,
ProcessFailed {
reason: Box<str>,
},
}Expand description
Semantic classification of an outbound ERP process event.
The ERP uses this to decide which action to take — update an order status, trigger a billing run, open a complaint ticket, etc.
Variants§
ProcessInitiated
A new MaKo process was spawned (e.g. inbound UTILMD received).
AperakAccepted
The counterparty sent an APERAK accepting our UTILMD.
AperakRejected
The counterparty sent an APERAK rejecting our UTILMD.
erc_code is Some when the APERAK carried a structured ERC segment
(BDEW APERAK AHB 1.0 §2.2). It is None for legacy outbox messages
that predate the typed ERC code field.
Fields
erc_code: Option<ErcCode>Structured BDEW ERC error code from the APERAK ERC segment.
Use crate::erc::recommended_action to derive the
recommended automated ERP response.
AperakTimeout
No APERAK received within the regulatory SLA window (deadline expired).
ContrlReceived
A CONTRL syntax acknowledgement was received.
ProcessCompleted
The process reached its terminal success state (e.g. Lieferbeginn/Lieferende confirmed).
MaloIdentified
A MaLo identification request was successfully resolved: the MaLo was found and the positive callback was delivered to the requesting LF.
The payload field of the associated ErpEvent carries a BO4E
Marktlokation JSON object with the resolved MaLo data.
ProcessFailed
The process failed permanently (regulatory timeout, data error, …).
Implementations§
Source§impl ErpEventType
impl ErpEventType
Sourcepub fn cloud_event_type(&self) -> &'static str
pub fn cloud_event_type(&self) -> &'static str
CloudEvents 1.0 type attribute for this event.
Follows the reverse-DNS prefix convention (de.mako.<domain>.<action>).
Used by the WebhookErpAdapter to populate the type field of the
CloudEvents envelope.
Trait Implementations§
Source§impl Clone for ErpEventType
impl Clone for ErpEventType
Source§fn clone(&self) -> ErpEventType
fn clone(&self) -> ErpEventType
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more