Add Kafka Bus to Architecture, Actor Topology and Data Flow diagrams
Browse filesUpdate developers-guide sections 2, 4, 5 to show KafkaBus publishing
orders/trades/market-data to Kafka topics from MECoreActor, alongside
the existing Event::Pipe flows to MDGActor and ClearingHouseActor.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- docs/developers-guide.md +33 -6
docs/developers-guide.md
CHANGED
|
@@ -102,6 +102,21 @@ EuNEx (Euronext Exchange Simulator) is a C++20 actor-based matching engine that
|
|
| 102 |
(β OEG) β (β MDG) β (β MDG) β
|
| 103 |
β β β
|
| 104 |
βββββββββββββββββββββͺβββββββββββββββββͺβββββββββββββββββͺββββββββββββββββββββββββ
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 105 |
β CORE 2 β Market Data βΌ βΌ β
|
| 106 |
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
|
| 107 |
β β MDGActor β β
|
|
@@ -208,6 +223,9 @@ EuNEx components are named to match Euronext Optiq production terminology:
|
|
| 208 |
MECoreActor ββTradeEventβββββββΊ MDGActor
|
| 209 |
ββBookUpdateEventββΊ MDGActor
|
| 210 |
ββTradeEventβββββββΊ ClearingHouseActor
|
|
|
|
|
|
|
|
|
|
| 211 |
|
| 212 |
AITraderActor ββNewOrderEventβββΊ OEGActor (via pipe)
|
| 213 |
```
|
|
@@ -232,15 +250,20 @@ EuNEx components are named to match Euronext Optiq production terminology:
|
|
| 232 |
ββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 233 |
β MECoreActor β
|
| 234 |
β β
|
| 235 |
-
β 1.
|
| 236 |
-
β 2.
|
| 237 |
-
β 3.
|
|
|
|
| 238 |
β a. Trade generated (buyer + seller session) β
|
| 239 |
β b. TradeEvent β MDGActor β
|
| 240 |
β c. TradeEvent β ClearingHouseActor β
|
| 241 |
-
β
|
| 242 |
-
β 5.
|
| 243 |
-
β 6.
|
|
|
|
|
|
|
|
|
|
|
|
|
| 244 |
ββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 245 |
β β
|
| 246 |
ExecReportEvent TradeEvent
|
|
@@ -267,6 +290,8 @@ EuNEx components are named to match Euronext Optiq production terminology:
|
|
| 267 |
```
|
| 268 |
MECoreActor ββTradeEventβββββββββββββββΊ MDGActor
|
| 269 |
ββBookUpdateEventβββββββββββΊ β
|
|
|
|
|
|
|
| 270 |
β
|
| 271 |
βΌ
|
| 272 |
ββββββββββββββββββββββββ
|
|
@@ -287,6 +312,8 @@ EuNEx components are named to match Euronext Optiq production terminology:
|
|
| 287 |
β
|
| 288 |
getSnapshot() / getRecentTrades()
|
| 289 |
(thread-safe, read by Python bridge)
|
|
|
|
|
|
|
| 290 |
```
|
| 291 |
|
| 292 |
---
|
|
|
|
| 102 |
(β OEG) β (β MDG) β (β MDG) β
|
| 103 |
β β β
|
| 104 |
βββββββββββββββββββββͺβββββββββββββββββͺβββββββββββββββββͺββββββββββββββββββββββββ
|
| 105 |
+
β KAFKA BUS (optional, Optiq KFK) β β β
|
| 106 |
+
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
|
| 107 |
+
β β KafkaBus (shared by all MECoreActors) β β
|
| 108 |
+
β β β β
|
| 109 |
+
β β β’ eunex.orders β raw Order on entry β β
|
| 110 |
+
β β β’ eunex.trades β Trade on each fill β β
|
| 111 |
+
β β β’ eunex.market-data β BBO snapshot on book update β β
|
| 112 |
+
β β β’ eunex.recovery.fragments β recovery data β β
|
| 113 |
+
β β β β
|
| 114 |
+
β β Enabled: EUNEX_USE_KAFKA=ON + EUNEX_KAFKA_BROKERS env var β β
|
| 115 |
+
β β Disabled: no-op stub compiles in (default) β β
|
| 116 |
+
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
|
| 117 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 118 |
+
β β β
|
| 119 |
+
βββββββββββββββββββββͺβββββββββββββββββͺβββββββββββββββββͺββββββββββββββββββββββββ
|
| 120 |
β CORE 2 β Market Data βΌ βΌ β
|
| 121 |
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
|
| 122 |
β β MDGActor β β
|
|
|
|
| 223 |
MECoreActor ββTradeEventβββββββΊ MDGActor
|
| 224 |
ββBookUpdateEventββΊ MDGActor
|
| 225 |
ββTradeEventβββββββΊ ClearingHouseActor
|
| 226 |
+
ββpublishOrder()βββΊ KafkaBus β eunex.orders (if Kafka enabled)
|
| 227 |
+
ββpublishTrade()βββΊ KafkaBus β eunex.trades (if Kafka enabled)
|
| 228 |
+
ββpublishMarketData()βΊ KafkaBus β eunex.market-data (if Kafka enabled)
|
| 229 |
|
| 230 |
AITraderActor ββNewOrderEventβββΊ OEGActor (via pipe)
|
| 231 |
```
|
|
|
|
| 250 |
ββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 251 |
β MECoreActor β
|
| 252 |
β β
|
| 253 |
+
β 1. KafkaBus.publishOrder() β eunex.orders * β
|
| 254 |
+
β 2. RecoveryProxy.cause() β persist fragment β
|
| 255 |
+
β 3. Book.newOrder() β price-time matching β
|
| 256 |
+
β 4. For each fill: β
|
| 257 |
β a. Trade generated (buyer + seller session) β
|
| 258 |
β b. TradeEvent β MDGActor β
|
| 259 |
β c. TradeEvent β ClearingHouseActor β
|
| 260 |
+
β d. KafkaBus.publishTrade() β eunex.trades * β
|
| 261 |
+
β 5. ExecReportEvent β OEGActor (ack/fill/reject) β
|
| 262 |
+
β 6. BookUpdateEvent β MDGActor (new BBO) β
|
| 263 |
+
β 7. KafkaBus.publishMarketData() β eunex.md * β
|
| 264 |
+
β 8. IACA fragments β IacaAggregator β
|
| 265 |
+
β β
|
| 266 |
+
β * only when EUNEX_KAFKA_BROKERS is set β
|
| 267 |
ββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 268 |
β β
|
| 269 |
ExecReportEvent TradeEvent
|
|
|
|
| 290 |
```
|
| 291 |
MECoreActor ββTradeEventβββββββββββββββΊ MDGActor
|
| 292 |
ββBookUpdateEventβββββββββββΊ β
|
| 293 |
+
ββpublishTrade()βββββββββββββΊ KafkaBus β eunex.trades *
|
| 294 |
+
ββpublishMarketData()ββββββββΊ KafkaBus β eunex.market-data *
|
| 295 |
β
|
| 296 |
βΌ
|
| 297 |
ββββββββββββββββββββββββ
|
|
|
|
| 312 |
β
|
| 313 |
getSnapshot() / getRecentTrades()
|
| 314 |
(thread-safe, read by Python bridge)
|
| 315 |
+
|
| 316 |
+
* KafkaBus publishes only when EUNEX_KAFKA_BROKERS is set at runtime
|
| 317 |
```
|
| 318 |
|
| 319 |
---
|