MetaMask / MetaMask/metamask-mobile
[Spike]: Investigate large numbers of API calls during app startup
- Dominant language
- TypeScript
- Stars
- 3k
- Forks
- 1.7k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 669
Description
### What is this about?
It was identified that our [App Start event](https://metamask.sentry.io/explore/traces/trace/87fea7b36df94e319ed06686e7dc2be6/?aggregateField=%7B%22groupBy%22%3A%22%22%7D&aggregateField=%7B%22yAxes%22%3A%5B%22p75%28span.duration%29%22%5D%7D&environment=production&fov=0%2C57304.436279296875&node=span-96319b7dcbe996fc&project=2299799&query=span.description%3A%22App%20Start%22&sort=-transaction&source=traces&statsPeriod=24h&targetId=96319b7dcbe996fc×tamp=1758043305) process has started having a large number of API calls immediately upon startup. It can be observed that at least 50 or more API calls occur on startup. This can bog down lower performing android devices and will get worse depending on the number of accounts a user has in their wallet.
- What options we have to optimize our app startup API calls?
- What is the impact if we stop polling on App Start Up?
- Improved start up times?
- Degraded wallet view UX?
### Scenario
_No response_
### Design
_No response_
### Technical Details
_No response_
### Threat Modeling Framework
_No response_
### Acceptance Criteria
_No response_
### Stakeholder review needed before the work gets merged
- [x] Engineering (needed in most cases)
- [ ] Design
- [ ] Product
- [ ] QA (automation tests are required to pass before merging PRs but not all changes are covered by automation tests - please review if QA is needed beyond automation tests)
- [ ] Security
- [ ] Legal
- [ ] Marketing
- [ ] Management (please specify)
- [ ] Other (please specify)
### References
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.