FastMM documentation
FastMM C++ API 0.6.0
Public headers, tier 1 and tier 2
Loading...
Searching...
No Matches
fastmm::ReconcileMsg Struct Reference

Control thread injects the venue's view after a reconnect (5.8). More...

#include <fastmm/core/messages.hpp>

Public Types

enum class  Kind : std::uint8_t { Begin = 0 , OpenOrder = 1 , Position = 2 , End = 3 }
 

Public Attributes

EventHeader hdr
 
Kind kind
 
Side side
 
OrderState state
 
std::uint8_t pad0_ [5]
 
ClientOrderId cl_ord_id
 
VenueOrderId venue_order_id
 
std::uint8_t pad1_ [7]
 
Price price
 
Qty orig_qty
 
Qty cum_qty
 
Qty position_qty
 Kind::Position.
 
Price avg_px
 Kind::Position.
 
ClientOrderId sent_watermark
 Kind::Begin, valid with kSentWatermark.
 
std::uint8_t flags
 Kind::Begin: kSentWatermark.
 
std::uint8_t pad_ [15]
 

Static Public Attributes

static constexpr std::uint8_t kSentWatermark = 1U << 0
 
static constexpr std::uint8_t kExecutionsExact = 1U << 1
 Begin: every execution the venue made since the last one the engine booked was replayed before this snapshot (Venue::request_executions succeeded), so the snapshot's quantities are the venue's own and nothing in it has to be guessed at.
 

Detailed Description

Control thread injects the venue's view after a reconnect (5.8).

A reconciliation is a Begin, N OpenOrder / Position records, then End.

Begin with kSentWatermark set carries the highest client order id (New or Replace) the venue had taken from the outbound ring when it requested the snapshot. Orders with a higher id were not yet sent, so the snapshot cannot contain them and End must not mark them cancelled. Without the flag every order of the venue missing from the snapshot is cancelled.

Member Enumeration Documentation

◆ Kind

enum class fastmm::ReconcileMsg::Kind : std::uint8_t
strong
Enumerator
Begin 
OpenOrder 
Position 
End 

Member Data Documentation

◆ kSentWatermark

constexpr std::uint8_t fastmm::ReconcileMsg::kSentWatermark = 1U << 0
staticconstexpr

◆ kExecutionsExact

constexpr std::uint8_t fastmm::ReconcileMsg::kExecutionsExact = 1U << 1
staticconstexpr

Begin: every execution the venue made since the last one the engine booked was replayed before this snapshot (Venue::request_executions succeeded), so the snapshot's quantities are the venue's own and nothing in it has to be guessed at.

Without it the connector could not ask, and a quantity the snapshot reports that no fill covered is an estimate: see Engine::book_missed_fill and Oms::reconcile_end.

◆ hdr

EventHeader fastmm::ReconcileMsg::hdr

◆ kind

Kind fastmm::ReconcileMsg::kind

◆ side

Side fastmm::ReconcileMsg::side

◆ state

OrderState fastmm::ReconcileMsg::state

◆ pad0_

std::uint8_t fastmm::ReconcileMsg::pad0_[5]

◆ cl_ord_id

ClientOrderId fastmm::ReconcileMsg::cl_ord_id

◆ venue_order_id

VenueOrderId fastmm::ReconcileMsg::venue_order_id

◆ pad1_

std::uint8_t fastmm::ReconcileMsg::pad1_[7]

◆ price

Price fastmm::ReconcileMsg::price

◆ orig_qty

Qty fastmm::ReconcileMsg::orig_qty

◆ cum_qty

Qty fastmm::ReconcileMsg::cum_qty

◆ position_qty

Qty fastmm::ReconcileMsg::position_qty

◆ avg_px

Price fastmm::ReconcileMsg::avg_px

◆ sent_watermark

ClientOrderId fastmm::ReconcileMsg::sent_watermark

Kind::Begin, valid with kSentWatermark.

◆ flags

std::uint8_t fastmm::ReconcileMsg::flags

Kind::Begin: kSentWatermark.

◆ pad_

std::uint8_t fastmm::ReconcileMsg::pad_[15]