alt/agent-ops/roadmap/milestones/socket-session-loop.md

1.9 KiB

Socket Session Loop

목표

Go API와 Flutter client 사이에 proto-socket 기반 최소 session loop를 만든다. 첫 loop는 handshake, request-response, disconnect/heartbeat 동작을 확인하는 데 집중하고, 무거운 데이터/백테스트 실행은 worker milestone로 넘긴다.

단계

기반 정렬

상태

계획

구현 잠금

  • 상태: 해제
  • 결정 필요: 없음

범위

  • API socket server의 ALT payload parser 등록
  • Hello request/response handshake
  • Flutter client의 proto-socket connection wrapper
  • 최소 request-response smoke path
  • API/client socket loop 테스트 또는 수동 검증 명령

필수 기능

  • [api-handshake] API가 ALT Hello request를 받고 Hello response를 반환한다.
  • [client-connect] Flutter client가 configured socket endpoint에 연결할 client layer를 갖는다.
  • [request-loop] 최소 request-response 메시지가 API와 client 사이에서 왕복한다.
  • [disconnect-state] client에서 연결/해제/오류 상태를 UI나 state layer에서 표현할 수 있다.
  • [socket-test] handshake loop를 검증하는 테스트 또는 반복 가능한 smoke 명령이 있다.

완료 기준

  • API와 client가 같은 contract typeName 기준으로 메시지를 주고받는다.
  • heartbeat/disconnect는 proto-socket 기본 동작을 따른다.
  • API가 long-running worker 작업을 직접 실행하지 않는다.
  • bin/testbin/lint가 통과한다.

범위 제외

  • market data import
  • backtest 실행
  • 인증/세션 권한 모델
  • 실시간 시세 streaming

작업 컨텍스트

  • 관련 경로: services/api/, apps/client/, packages/contracts/, ../proto-socket/
  • 표준선(선택): API는 socket/session boundary를 맡고, worker execution은 worker milestone에서 다룬다.
  • 선행 작업: Contract and Codegen Baseline
  • 후속 작업: Flutter Operator Console
  • 확인 필요: 없음