Symbol & data refactoring for Nautilus

This commit is contained in:
2026-04-01 00:59:13 -04:00
parent cd28e18e52
commit 93bc8a3a4f
55 changed files with 537 additions and 600 deletions

View File

@@ -77,7 +77,7 @@ The relay acts as a well-known bind point for all components:
```
1. Client subscribes to ticker
Socket: SUB → XPUB (5558)
Topic: "BINANCE:BTC/USDT|tick"
Topic: "BTC/USDT.BINANCE|tick"
2. Relay forwards subscription
Socket: XSUB → Flink PUB (5557)

View File

@@ -205,13 +205,13 @@ impl Relay {
info!("Handling request submission: request_id={}, ticker={}, client_id={:?}",
request_id, ticker, client_id);
// Extract exchange prefix from ticker
let exchange_prefix = ticker.split(':').next()
.map(|s| format!("{}:", s))
// Extract exchange suffix from ticker (Nautilus format: "BTC/USDT.BINANCE")
let exchange_prefix = ticker.rsplitn(2, '.').next()
.map(|s| format!("{}.", s))
.unwrap_or_else(|| String::from(""));
if exchange_prefix.is_empty() {
warn!("Ticker '{}' missing exchange prefix", ticker);
warn!("Ticker '{}' missing exchange suffix", ticker);
}
// Build DataRequest protobuf for ingestors