After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 771904 - Don't load all contacts into memory at startup
Don't load all contacts into memory at startup
Status: RESOLVED OBSOLETE
Product: geary
Classification: Other
Component: engine
master
Other Linux
: Normal normal
: ---
Assigned To: Geary Maintainers
Geary Maintainers
Depends on: 771903
Blocks:
 
 
Reported: 2016-09-24 02:40 UTC by Michael Gratton
Modified: 2019-03-17 04:50 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Michael Gratton 2016-09-24 02:40:23 UTC
When Geary starts, each Engine instance loads all contacts from the DB and puts them in an instance of Geary.ContactStore. Then, when constructing a new composer instance, these get copied into an instance of ContactListStore and used for email address completion. Since contacts are GObjects, for accounts with many contacts (I have 65k in one), this constitues something of a CPU and memory overhead.

Both Geary.ContactStore and ContactListStore could load contacts on-demand from the database instead, reducing both overheads, or some other approahc could be taken, like just removing Geary.ContactStore.

However, Bug 713232 seems to imply the way contacts currently work was a conscious choice, so some care should be taken before committing this. Fixing Bug 771903 may also reduce the importance of this a bit as well.
Comment 1 Michael Gratton 2019-03-17 04:50:26 UTC
Closing in favour of: https://gitlab.gnome.org/GNOME/geary/issues/318