All contract interactions is stored as events and currently no aggregation is stored. Due to this every time balance or current linked module needs to be found, all events needs to be loaded into memory.
Due to some other memory issues, on mainnet the CCD Scan query pod has now got both a CPU- and memory limit. Because of this we are suddently not able to see contract overview page, see issue https://github.com/Concordium/concordium-scan/issues/194.
This is because all events for all contracts needs to be loaded just to deliver this one view.
This PR adds a snapshot of contract state.
Changes
Add contract snapshot to import flow
Add contract snapshot migration
Update contract graphql queries
Update frontend
Checklist
[x] My code follows the style of this project.
[ ] The code compiles without warnings.
[x] I have performed a self-review of the changes.
[x] I have documented my code, in particular the intent of the
hard-to-understand areas.
Purpose
All contract interactions is stored as events and currently no aggregation is stored. Due to this every time balance or current linked module needs to be found, all events needs to be loaded into memory.
Due to some other memory issues, on mainnet the CCD Scan query pod has now got both a CPU- and memory limit. Because of this we are suddently not able to see contract overview page, see issue https://github.com/Concordium/concordium-scan/issues/194.
This is because all events for all contracts needs to be loaded just to deliver this one view.
This PR adds a snapshot of contract state.
Changes
Checklist