storgae clean up#698
Conversation
|
Tight, focused cleanup on the escrow error surface and a small staking test follow-up. Easy to review. Merging. ✅ |
|
🟡 Holding for author coordination. This PR and #677 both modify the same files ( |
nanaf6203-bit
left a comment
There was a problem hiding this comment.
🚧 The escrow analytics field + EscrowAnalytics::Default impl looks clean, but the branch has merge conflicts with main right now, so I cant land it cleanly. Could you rebase onto main (or pull in the latest changes) and ping me when its green? I will approve and merge once conflicts are resolved. Closes #511 once it lands.
closes #511
Summmary
This PR implements a long-overdue storage optimization mechanism for the escrow contract. Currently, escrow data (documents, conditions, signatures, audit logs) persists indefinitely after completion, causing unnecessary on-chain storage bloat. This change introduces a cleanup mechanism that removes detailed escrow data while preserving essential information for compliance and historical reference.
Key Changes
New Features
cleanup_escrow(escrow_id)- New public message allowing any participant or admin to clean up a completed escrowget_escrow_summary(escrow_id)- New query to retrieve summary information for cleaned-up escrowsValidation Rules
Completed,Released, orRefundedPending,InProgress,Disputed)Performance Impact
Testing