Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThe changes introduce eCurrency account functionality through new documentation, JSON schema definition, and a backfill script that populates existing account data from the ledger into user and group eVaults using GraphQL mutations. Changes
Sequence DiagramsequenceDiagram
participant Script as Backfill Script
participant DB as Application Database
participant Registry as eVault Registry
participant eVault as eVault Service
participant TokenSvc as Token Service
Script->>DB: Query distinct (accountId, accountType, currencyId) from Ledger
DB-->>Script: Return account combinations
Script->>Script: Compute balance & createdAt per account
Script->>Script: Group accounts by holder eVault
loop For each holder eVault
Script->>Registry: Resolve eVault URL for holder eName
Registry-->>Script: eVault URL
Script->>eVault: Query existing MetaEnvelopes (ledger & account ontologies)
eVault-->>Script: Existing envelopes
Script->>Script: Filter out duplicate accounts by accountId & currencyEname
alt Account not exists
Script->>TokenSvc: Get/refresh platform token (on 401)
TokenSvc-->>Script: Access token
Script->>eVault: Bulk create account MetaEnvelopes (batched)
eVault-->>Script: Success/error per envelope
else Account exists
Script->>Script: Skip (already backfilled)
end
end
Script->>Script: Aggregate and log totals
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
c8555f6 to
6761de8
Compare
6761de8 to
3e57361
Compare
Description of change
Issue Number
Type of change
How the change has been tested
Change checklist
Summary by CodeRabbit
Release Notes
Documentation
Chores