Serve last execution prices and directions for individual and batch token queries
This commit is contained in:
@@ -1005,3 +1005,24 @@ sequenceDiagram
|
||||
R-->>W: 数据与内部继续位置
|
||||
W-->>H: 公开点字段、偏移和 URL 安全的继续游标
|
||||
```
|
||||
|
||||
### 最近成交价与方向
|
||||
|
||||
```mermaid
|
||||
flowchart LR
|
||||
H["cli/market_http.rs"] --> L["last_trades.rs"]
|
||||
W["market_stream.rs"] -->|复用成交方向换算| L
|
||||
L --> Q["last_trades.sql"]
|
||||
```
|
||||
|
||||
```mermaid
|
||||
sequenceDiagram
|
||||
participant H as HTTP
|
||||
participant L as last_trades
|
||||
participant D as SQLite
|
||||
H->>L: 请求资产列表
|
||||
L->>D: 单条查询联结每个资产的最近成交、成交上下文和吃单委托
|
||||
D-->>L: 成交价格及吃单方结果和方向
|
||||
L->>L: 对互补结果反转方向;缺少吃单记录时方向留空
|
||||
L-->>H: 按输入顺序返回,保留重复项
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user