Track user accounts over time with the following data:
User
[ ] active: boolean: true if a user account ever made a transaction (event Tokens.Transfer)
[ ] vault: number: increment for every vault that this account has registered (event VaultRegistry.VaultRegistered)
[ ] issued: number: increment for every issue request made by this account (event Issue.ExecuteIssue)
[ ] redeemed: number: increment for every redeem request made by this account (event Redeem.ExecuteRedeem)
[ ] bridged: number: increment for every issue or redeem request made by this account (event Issue.ExecuteIssue and Redeem.ExecuteRedeem)
[ ] staked: number: increment when a user stakes INTR/KINT (event Escrow.Deposit)
[ ] voted: number: increment when a user votes in a governance proposal (event missing)
[ ] lend: number: increment when a user deposits funds into the lending protocol (event Loans.Deposited)
[ ] borrowed: number: increment when a user borrows funds (event Loans.Borrowed)
[ ] swapped: number: increment when a user does a swap (event DexGeneral.AssetSwapDexStable.CurrencyExchange)
[ ] lp: number: increment when a user supplies liquidity (event DexGeneral.LiquidityAddedDexStable.AddLiquidity)
[ ] crowdloan: boolean: true if the user has a vesting schedule (event Vesting.VestingScheduleAdded)
We do this in airflow at the moment, but it's pretty terrible in terms of complexity: it grows linear with the amount of users, amount of transactions, ... and will eventually run way too long. We can do it with a lot less overhead in squid.
Track user accounts over time with the following data:
User
Tokens.Transfer
)VaultRegistry.VaultRegistered
)Issue.ExecuteIssue
)Redeem.ExecuteRedeem
)Issue.ExecuteIssue
andRedeem.ExecuteRedeem
)Escrow.Deposit
)Loans.Deposited
)Loans.Borrowed
)DexGeneral.AssetSwap
DexStable.CurrencyExchange
)DexGeneral.LiquidityAdded
DexStable.AddLiquidity
)Vesting.VestingScheduleAdded
)We do this in airflow at the moment, but it's pretty terrible in terms of complexity: it grows linear with the amount of users, amount of transactions, ... and will eventually run way too long. We can do it with a lot less overhead in squid.