Overview
Several non-obvious design decisions in the contracts lack documentation. Future contributors and auditors cannot determine whether a choice was intentional or accidental. Architecture Decision Records (ADRs) capture the why behind key choices.
ADRs Required
ADR-001: Dual Credit Systems (Boost/Stake vs Lock/Unlock)
- Why does the pool have two independent credit accrual mechanisms?
- When should a user use
stake/unstake vs lock_assets/unlock_assets?
- How are credits from both systems intended to be combined?
ADR-002: Factory-Deployed vs Standalone Pool Deployment
- Why are pools deployed via a factory rather than standalone?
- What is the security model for verifying a pool's authenticity (
pool_wasm_hash check)?
- Trade-offs of deterministic salt vs random salt
ADR-003: TTL Extension Strategy
- Why are TTLs extended on every read/write rather than only on writes?
- What are the cost implications?
- What happens to user data when TTL expires?
ADR-004: Credit Accrual without On-Chain Token Minting
- Why do credits exist as a counter rather than as minted tokens?
- How does the credit-to-reward conversion work (planned or current)?
- Why not use a standard Soroban token for credits?
ADR-005: Pause Mechanism Scope
- Why does pause block user functions but not admin functions?
- What is the intended recovery procedure after a pause?
Format
Store ADRs as docs/decisions/ADR-00N-title.md using the standard format:
# ADR-NNN: Title
## Status: Accepted
## Context
## Decision
## Consequences
Acceptance Criteria
Overview
Several non-obvious design decisions in the contracts lack documentation. Future contributors and auditors cannot determine whether a choice was intentional or accidental. Architecture Decision Records (ADRs) capture the why behind key choices.
ADRs Required
ADR-001: Dual Credit Systems (Boost/Stake vs Lock/Unlock)
stake/unstakevslock_assets/unlock_assets?ADR-002: Factory-Deployed vs Standalone Pool Deployment
pool_wasm_hashcheck)?ADR-003: TTL Extension Strategy
ADR-004: Credit Accrual without On-Chain Token Minting
ADR-005: Pause Mechanism Scope
Format
Store ADRs as
docs/decisions/ADR-00N-title.mdusing the standard format:Acceptance Criteria
docs/decisions/directory createddocs/README.mdlinks to all ADRs