Market Data Updates
Apart from the Market Data updates that are sent as a result of subscription flags, there are other updates that can eventually be sent to clients during the trading day. We strongly recommend that clients implement the corresponding handling logic for these as they can carry meaningful updates.
SecurityDefinitionEventData
The SecurityDefinitionEventData
carries information about freshly created securities during the trading day, as well as changes in already created securities that were queried via the GetSecurityListRequest.
Here follows a non-exhaustive list of relevant changes in securities that can happen during the day:
- Creation of strategies (UDS - user defined strategies)
- Change in the Theoretical Portfolio by the feed handler instance manager
Clients should implement the handling logic for this message to update their internal security list once new instruments are created intraday by the Exchange.
EmptyBookEventData
The EmptyBookEventData
message is sent when the exchange resets the channel or an instrument belonging to a channel. This message is sent to all clients that have a subscription to the affected instrument. Upon receiving this message, clients should clear the orderbook based on the flags emptyBidSide
or emptyOfferSide
. If both flags are set, the client should clear the entire orderbook.
IncrementalUpdateEventData and FullMarketByOrderSnapshotEventData
When requesting the SubscriptionType.Market_By_Order_Full
subscription type, clients will receive IncrementalUpdateEventData
messages to handle the orderbook themselves.
In order to synchronize the orderbook, clients need to follow the steps below:
- Immediately after sending the subscription request, clients may start receiving
IncrementalUpdateEventData
messages (for liquid instruments) before receiving aFullMarketByOrderSnapshotEventData
message. The incremental update messages should be queued until the snapshot is received. - Upon receiving the
FullMarketByOrderSnapshotEventData
message, clients should add the orders from the snapshot to the orderbook and record theinstrumentSequenceNumber
of theFullMarketByOrderSnapshotEventData
message. - After applying the snapshot to the orderbook, clients can go through the queued
IncrementalUpdateEventData
messages and apply them to the orderbook. TheinstrumentSequenceNumber
of theIncrementalUpdateEventData
message should be compared to theinstrumentSequenceNumber
of theFullMarketByOrderSnapshotEventData
message. If theinstrumentSequenceNumber
of theIncrementalUpdateEventData
message is less than or equal to theinstrumentSequenceNumber
of theFullMarketByOrderSnapshotEventData
message, the message should be discarded (as it is already being accounted for in the current state of the snapshot). Once theinstrumentSequenceNumber
of theIncrementalUpdateEventData
message is greater than theinstrumentSequenceNumber
of theFullMarketByOrderSnapshotEventData
message, clients should start applying the incrementals and updating the orderbook sequence number accordingly.