Keyed current state
The latest row per instrument is always ready, maintained from the trade feed by transformations.
Your trade feed, the latest state per instrument and the live analytics over both, in one place, with no cache to keep in sync with the store.
The problem
Your trading stack splits one workflow across four systems: a tick store for history, a cache for the current book, a stream processor for signals and a warehouse for backtests. Every hop serializes the data again, and every copy is a chance for the cache to disagree with the store.
The disagreement surfaces exactly when it hurts: a strategy reads state that a fill just changed. In trading, a stale read against a fresh write is not a rounding error. It is a wrong decision.
What you want is one place where every trade is durable, the current state per instrument is kept from it continuously, and every consumer follows both live without polling.
Architecture
Trades land in one durable table. The engine publishes every committed write once, to the transformations that keep per-instrument state and to every STREAM SELECT that follows the feed.
Every trade is on disk before you get the acknowledgement: the node’s write-ahead log persists it first.
Readers never slow the writer: each committed batch is published once, and every subscriber keeps its own durable cursor over the relation and key it selected.
The latest state per instrument is always ready to read: a transformation folds the trade feed into an UPSERT table keyed by instrument, with COUNT, SUM, MIN, MAX and AVG lanes.
Follow one instrument or a grouped total live with STREAM SELECT; dashboards and backtests run ordinary SELECTs over the same tables.
Examples
CREATE TABLE transfers ( chain_id UINT16 NOT NULL, token STRING NOT NULL, sender STRING NOT NULL, recipient STRING NOT NULL, amount UINT256 NOT NULL, transferred_at DATETIME64(3, 'UTC') NOT NULL, _index UINT128 NOT NULL, INDEX transfers_ts (transferred_at) USING MINMAX SCOPE HISTORY GRANULE 8192)MODE APPENDSHARD BY (token) SHARDS AUTOPARTITION BY MONTH(transferred_at)ORDER BY (chain_id, token, _index)STORAGE PROFILE COLUMNAR;STREAM SELECT chain_id, token, SUM(amount) AS volume, COUNT(*) AS transfersFROM transfersGROUP BY chain_id, token;The examples use the same two tables on every page. See the SQL reference for full syntax.
Capabilities
The latest row per instrument is always ready, maintained from the trade feed by transformations.
Counts, sums, minimums, maximums and averages stay current, with arithmetic over them for VWAP-style prices.
One snapshot, then every change as commits land, with STREAM SELECT.
Choose ROW, COLUMNAR or HYBRID storage per table, to match how you read it.
Tick store, keyed state and stream fan-out run in one node process.
A write is acknowledged only after the write-ahead log persisted it.
Learn more
Start a node and follow your first market feed live.