To debug aggregated orderbook feature, debug probes can be enabled.
It will allow publishing internal orderbook input (operations) to AMQP topic
peatio.events.ranger
to admin._market_.op
routing key.
Operation model:
Field | Description |
---|---|
Market | Market ID |
Type | Init, Update, Delete, Disable, Limit, ClearDriver, Resync |
Side | sell or buy |
Price | Price |
Amount | Amount |
Driver | Driver (upstream) |
SourceID | Source order ID |
TraceID | Trace ID |
It also adds trace_id
to raw orders and raw order snapshots.
TraceID is assigned to input operation and all outputs, caused by this operation.
It means that several raw orders (outputs) can have same traceID and there will be one operation with this ID (input).
TraceIDs have different prefixes:
OP_
+ incremental number for operationsTICKER_
+ timestamp for snapshot tickerSYNC_
+ timestamp for periodic resync operationTIMER_
+ timestamp for optional disconnect timer (if no activity driver is considered disconnected)Also there is a tool to record AMQP messages, ./cmd/amqp_daemon
Recorded outputs can be validated with a script ./scripts/check-ob.rb