Open MSilb7 opened 5 months ago
Example queries where these joins (and lack of native evms
) creates query timeout
Thanks @MSilb7 ! Love the input, and especially providing two alternatives.
This is on our radar and has been for a while. I would however not hold my breath, as this is not something we have planned to do just yet!
Description
Currently, when querying cross-chain raw tables (i.e.
evms.traces
) or spells (i.e.nft.transfers
), we have to do intensive joins to pull top-level transaction data (evms.transactions
) which cause query timeouts.Proposal
Add all transactions fields to the lower-level traces, logs, nft transfers, dex trades, nft trades, etc tables (i.e. gas_used, gas_price, l1_fee, l1_gas_used, data, gas_limit)
Alt
Another alternative (imo much better) solution would be to make the
emvs
schema "native" rather than being a view of lower-level blockchain tables. "Single-chain" queries are becoming more and more rare in my experience, andemvs
performance is a drag. See - https://github.com/duneanalytics/spellbook/issues/4693This saves computation query resources & eliminates the manual overhead to track which chains need which fields. It should also make cross-chain spell design infinitely easier, since we won't need to duplicate models for each chain.