kjh2064
|
2bc2b1ec6f
|
feat: Complete VS-03 BE+ASYNC - Market Data Ingestion (Batch 2 - 5/7)
Implements market data ingestion REST API and Hangfire scheduler:
✅ BE (REST Endpoints):
- POST /api/market/ingest: Trigger data ingestion (202 Accepted)
- GET /api/market/ingest/{jobId}: Check ingestion status
- Idempotency: By (dataSource, fromDate, toDate)
- Audit: Correlation ID tracing
✅ ASYNC (Hangfire Job):
- Daily 9:00 KST scheduling
- Flow: Fetch → Validate → Normalize → Persist → Event publish
- MarketDataSyncedEvent: Published when sync completes
- Idempotency: No re-run for same date range
- Status tracking: Queued → Running → Completed/Failed
✅ Application Handler:
- IMarketDataIngestionService: Orchestrates ingestion
- Job scheduling with correlation ID
- Event publishing to outbox
- Status persistence to ingestion_jobs table
✅ Abstractions:
- IMarketDataDataSourceClient: KRX/OpenDart/Stub
- StubMarketDataClient: Testing implementation
AGENTS.md v16.0 compliance:
✅ Idempotency: By date range (same range = no re-run)
✅ Traceability: CorrelationId + JobId tracking
✅ Audit: All state changes logged
✅ Safety: Transaction-safe persistence
✅ Maturity: Contract-first design
Phase 2 Progress: Batch 2 (5/7 COMPLETE - missing FE + TESTOPS)
Next: VS-04~08 or Phase 3 validation
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
|
2026-08-05 21:19:25 +09:00 |
|