Skip to content

FEATURE: [xmaker] poll source order book via REST when stale - #2821

Open
dboyliao wants to merge 1 commit into
dboy/orderbook/update-monitorfrom
dboy/orderbook/poll-source-book-on-stale
Open

dboyliao wants to merge 1 commit into
dboy/orderbook/update-monitorfrom
dboy/orderbook/poll-source-book-on-stale

Conversation

@dboyliao

@dboyliao dboyliao commented Nov 24, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Test plan

  • go build ./pkg/strategy/xmaker/...
  • go test ./pkg/strategy/xmaker/...
  • gofmt -s -l / go vet clean

🤖 Generated with Claude Code

@dboyliao
dboyliao requested a review from c9s November 24, 2026 13:13
@dboyliao
dboyliao force-pushed the dboy/orderbook/poll-source-book-on-stale branch from 3c2fa94 to ca3364c Compare November 25, 2026 02:05
@dboyliao
dboyliao force-pushed the dboy/orderbook/update-monitor branch from 1900037 to ccffc05 Compare November 25, 2026 02:05
@dboyliao
dboyliao force-pushed the dboy/orderbook/poll-source-book-on-stale branch from ca3364c to c74b950 Compare November 25, 2026 02:31
@dboyliao
dboyliao force-pushed the dboy/orderbook/update-monitor branch from ccffc05 to 19f0dc0 Compare November 25, 2026 02:31
@dboyliao
dboyliao force-pushed the dboy/orderbook/poll-source-book-on-stale branch 2 times, most recently from 339ac26 to 7ea198f Compare November 25, 2026 03:19
@dboyliao
dboyliao force-pushed the dboy/orderbook/update-monitor branch from 19f0dc0 to 4676312 Compare November 25, 2026 03:20
@dboyliao
dboyliao force-pushed the dboy/orderbook/update-monitor branch from 4676312 to 8ce869c Compare November 25, 2026 07:32
@dboyliao
dboyliao force-pushed the dboy/orderbook/poll-source-book-on-stale branch from 7ea198f to 219ed36 Compare November 25, 2026 07:32
Wires types.StreamBookMonitor into the strategy as an optional
sourceBookUpdateMonitor config block, bound to the source book right
after BindStream. In the quote loop, when it reports the book stale, the
hedge exchange is polled for a fresh depth snapshot via REST (if it
implements types.ExchangeDepthQueryService) before reading best bid/ask.
The existing PriceHeartBeat/reconnect safety net is unchanged and still
applies if the book remains stale.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@dboyliao
dboyliao force-pushed the dboy/orderbook/poll-source-book-on-stale branch from 219ed36 to 458c32c Compare November 25, 2026 07:52
@dboyliao
dboyliao force-pushed the dboy/orderbook/update-monitor branch from 8ce869c to 02b4a69 Compare November 25, 2026 07:52

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants