BAT-042 (dcy-028 / issue #26 C-1/C-2/C-2b/C-3, REQ-079~082 + REQ-073/074 CHG): - slot_strategy_state 별도 테이블 + StrategyStateStore(in-memory+PG) + occupancy_seq·version CAS + opaque UTF-8 data + 2단 size cap (REQ-079) - trex.slots.strategy_state.set write RPC — reject reason 집합, 멱등 (REQ-080) - Slot.occupancy_seq 필드 + inactive→pending_buy bump + →INACTIVE close 삭제 훅 → 점유 전환 ABA 구조적 차단 (REQ-081) - slots.req 응답 행에 strategy_state 맵(batched 조립)·occupancy_seq additive (REQ-073 AC-7/REQ-074 AC-6) - 마이그레이션 014(occupancy_seq)/015(slot_strategy_state), baseline 문서 정합 (REQ-082) BAT-043 (issue #27 / REQ-007 CHG): - rejected SellIntent 응답에 additive retryable: bool (core 소유 reason→retryable 매핑, 미인식 기본 true, bad_request* false) — 손절매 재시도 안전 경로 decoupling 검증: 487 passed, 47 skipped (신규 41: store CAS 6+ABA, occupancy bump/close 4경로, set RPC 9, slots read 5, retryable 8, PG 게이트), ruff clean. REQ-079·080·081·082·073·074·007 → Implemented. issue #27 close. PG 경로 실 DB 검증은 release 위임. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1.4 KiB
1.4 KiB
BAT-043 Planning
- Status: confirmed
- Batch: BAT-043
- Profile: batch-lite
Included REQ
- REQ-007 (CHG-20260615-01) — rejected SellIntent 응답 additive
retryable: bool
Delivery Plan
messaging_handlers.py에 core 소유_SELL_REJECT_RETRYABLE매핑 + helper(_sell_retryable(reason)— 미인식 기본 true,bad_request:*/terminal → false).- intent 응답 빌더:
intent_type=="sell"且status=="rejected"일 때만retryable부여. bad_request 조기반환 경로(sell 식별 가능 시)도 동일 적용. - 테스트 추가 + interface-contract 문서 정합.
Dependencies
- Internal:
messaging_handlers.make_intent_rpc_handler(응답 빌더),intents.py(reason 어휘 — _admit_sell/_dedup). - External: trex-tsl 데몬(소비자, 별도 저장소) — 폴백 보유로 lockstep 불요.
Design Gate
- Design Required Before Implementation: no
- Reason: 단일 additive 응답 필드 + 순수 매핑(dict). 구조/런타임 흐름/스키마 영향 없음. 계약 변화는 interface-contract 한 줄. design.md 불요(batch-lite).
Milestones
- 매핑 + helper + 응답 빌더
- 테스트 + 문서
Risks
- reason 어휘 drift: 매핑이 core 에 있어 새 reason 추가 시 함께 갱신(미인식 기본 true 가 안전망). — 매핑 테스트로 현행 reason 전수 커버.
- bad_request 경로: sell 여부 판별 가능 지점에서만 retryable=false 부여(불명확하면 미부여 — 데몬 폴백).