Function lookup_order_intent
pub fn lookup_order_intent(
state: &PortfolioState,
batch_intent_cache: &HashMap<OrderId, ClientIntentId>,
order_id: &OrderId,
) -> Option<ClientIntentId>Expand description
Resolve originating ClientIntentId for an order lifecycle event.
Prefers the batch-local cache (for Ack/Fill in the same execution poll),
then falls back to open_orders, then terminal_order_attribution.
Shared between the live runner and the backtest engine (PARITY).