Skip to content

feat(market-data): add bar continuity prefill and recovery - #158

Open
LimiNode wants to merge 2 commits into
mainfrom
feat/market-data-continuity
Open

feat(market-data): add bar continuity prefill and recovery#158
LimiNode wants to merge 2 commits into
mainfrom
feat/market-data-continuity

Conversation

@LimiNode

@LimiNode LimiNode commented Sep 3, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add configurable bar continuity modes: live-only, prefill, and prefill with recovery.
  • Prefill historical bars, buffer live batches during prefill, and transition into the live stream.
  • Detect timestamp gaps, request bounded backfill, merge multiple gaps, and route continuity status per subscription.
  • Track every accepted history operation independently from route entries so shutdown cannot complete before late history callbacks are observed.
  • Validate returned history metadata against the subscribed type, symbol, and timeframe before delivery or timestamp updates.
  • Add focused regressions for deferred/failed history during shutdown, foreign-stream history responses, and inclusive prefill ranges.
  • Run the continuity test and example explicitly in both Ubuntu and Windows smoke workflows.
  • Add synchronized EN/RU documentation and publish final non-tradable condition snapshots during TradingConditionManager shutdown.

Verification

  • market_data_continuity_test: 11/11 (MinGW)
  • market_data_router_test: 21/21 (MinGW)
  • market_data_subscription_contract_test: 22/22 (MinGW)
  • market_data_continuity_example: passed
  • git diff --check: passed

The full intrade_bar_api_response_test was not built locally because the local build-libs artifacts are stale: mdbx-containers is missing ValueTable.hpp and the local kurlyk lacks the expected HttpRateLimitHandlePtr API. The continuity changes are covered by the focused tests and example.

Follow-ups

  • Add a generic tick-history provider contract when a provider can support it.
  • Consider provider-aware retry/backoff, sequence validation, deduplication policy, metrics, and CMake package/export integration.

Add route-scoped bar history prefill, buffered live delivery, timestamp gap recovery, and continuity status events to MarketDataRouter. Document the EN/RU contract, add a deterministic chart example and regression coverage, and publish final unavailable trading-condition snapshots during platform shutdown.
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.

1 participant