element-hq / element-hq/element-ios

Lazy load other things from the cache

Open
#4,386 0 comments 0 reactions 0 assignees View on GitHub
A-Startup P2 performance
Dominant language
Swift
Stars
1.8k
Forks
544
PR merge metrics
PR metrics pending

Description

After #4382, #4383, #4384, #4385, we may want to lazy load MXUsers and MXGroups but the gain will be minimal comparing to others.

We want to kill the 71ms and 1ms in this log:

```
[MXFileStore] Start data loading from files
[MXFileStore] Loaded room messages of 625 rooms in 828ms
[MXFileStore] Loaded rooms summaries data of 625 rooms in 572ms
[MXFileStore] Loaded rooms account data of 625 rooms in 359ms
[MXFileStore] Loaded read receipts of 625 rooms in 1035ms
[MXFileStore] Loaded 2164 MXUsers in 71ms
[MXFileStore] Loaded 2 MXGroups in 1ms
[MXBaseProfiler] Task startup - storePreload for 625 units completed in 2870.760ms
[MXFileStore] Data loaded from files in 2871ms

Contributor guide

Open the contributing guide

Research direction

Start with MXFileStore's startup preload path and review issues #4382 through #4385 for the preceding lazy-loading work. Compare the logged MXUsers and MXGroups loading steps with the target behavior; done means those remaining cache loads no longer contribute their reported startup time.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
mobile-dev, performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.