When is DeletedContacts table in contacts.db cleared?
I have had problems with sync and removed and re-added my google account a couple of times to remedy for contacts disappearing (they still do in 3.0.1 for me). Lately my phone began to behave sluggish and only one or two application could be open at a time before OOM killed them. Found that contactsd consumed a lot of RAM (1.8GB for me!) and to fix this I followed the advice here.
When I copied contacts.db to my computer it was 746MB(!) and the table DeletedContacts had 5 268 602 rows (that's more than 5 million rows...). I don't know what this table does, but I think it should be periodically cleared. Rows date from 2018-07-10 (that's when I first flashed my XperiaX).
Also, does anyone know if this table is safe to purge?
Edit: I removed all entries in that table hoping it would fix the memory consumption issue, but contactsd still consumes 1,1GB RAM, even with only local contacts and less than 10 of them. 1,6GB RAM peek, when I add google and exchange accounts and sync.
I removed the db (as recommended in this thread) and it solved the memory consumption. Still doesn't fix the size on disk.
Mohjive ( 2019-02-11 11:43:14 +0200 )edit