[P2][refactor] LeaseRegistry 책임 분리 및 port/runtime mutation transaction화 #36
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
문제
crates/portal-relay/src/relay/leases.rs의LeaseRegistry가 challenge 발급/검증, SIWE 연계, lease register/renew/unregister, token verify, UDP/TCP runtime 생성, port allocator, hop route, public/admin view, policy 확인, stream admission 등을 모두 담당합니다.영향
제안 구조
특히 port allocation과 runtime start는 lease state mutation과 분리해 transaction/rollback을 명확히 하는 것이 좋습니다.
완료 기준
검토 기준: 업로드된 Rust
portal-relay코드 정적 리뷰. 리뷰 환경에서는cargo check/test/clippy를 실행하지 못했습니다.검토했지만 이번 범위에서는 수용하지 않습니다. LeaseRegistry 분리는 장기 유지보수 과제이지만, 즉시 필요한 결함인 TTL cap, hop policy, queue/port 재등록 문제는 PR #62에서 좁게 수정했습니다. 대형 transaction/refactor는 호환성 회귀 위험이 커서 별도 로드맵 전까지 닫습니다.