refactor: 동기 주문 경로 완전 제거 (#121)#122
Conversation
동기 체결 경로에서만 쓰이던 SyncOrderProcessor, CreateOrderResponse 삭제. OrderService에서 동기 처리 로직도 함께 정리.
/async 엔드포인트 제거하고 / 로 일원화. 이제 모든 주문 생성은 202 Accepted 반환.
DB에서 읽어온 BigDecimal이 scale-18로 들어오면서 100000000.000000000000000000 형태로 노출되던 문제 수정. stripTrailingZeros().toPlainString() 적용.
동기→비동기 전환 이후 워커 처리 완료 전에 assertion 하면서 터지던 테스트 수정. Awaitility로 각 테스트에서 워커 완료 대기 추가.
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughRemoves the synchronous order creation path ( ChangesAsync Order Path Consolidation
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related issues
Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
배경
멘토 코드 리뷰에서 sync/async 경로가 공존하는 구조가 혼란스럽다는 피드백.
이제 async 경로만 남겨두고 동기 체결 관련 코드 전부 제거.
변경 사항
프로덕션
SyncOrderProcessor,CreateOrderResponse삭제OrderService에서 동기 체결 로직 제거POST /orders/async→POST /orders로 통합, 모든 주문 생성은 202 Accepted 반환stripTrailingZeros()적용)테스트
커밋 구성
refactor: SyncOrderProcessor 제거refactor: POST /orders 단일 경로로 통합fix: 오더북 가격 표시 오류 수정test: 비동기 워커 완료 대기 추가Closes #121
Summary by CodeRabbit
API Changes
Bug Fixes
Tests