Review Request 122444: Improve the contacts cache for KPeople
David Edmundson
david at davidedmundson.co.uk
Sun Feb 8 10:47:19 UTC 2015
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/122444/#review75589
-----------------------------------------------------------
kpeople/datasourceplugin/im-persons-data-source.cpp
<https://git.reviewboard.kde.org/r/122444/#comment52283>
having both the kpeople cache AND the avatars cache is silly.
They need to be merged.
ship this if you want for now, but even medium term we need to fix the above comment.
- David Edmundson
On Feb. 5, 2015, 6:11 p.m., Martin Klapetek wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/122444/
> -----------------------------------------------------------
>
> (Updated Feb. 5, 2015, 6:11 p.m.)
>
>
> Review request for Telepathy.
>
>
> Repository: ktp-common-internals
>
>
> Description
> -------
>
> Currently when account goes online from offline, the contact cache is completely nuked and recreated. This is fast but has one drawback - it will store avatars only of those contacts that are online in the moment of connection, so basically with each connection the available avatars change a bit. To compensate, we've been storing the avatar token in a config file, but that's used only for KTp::Contact.
>
> Now with KPeople, if the account is offline, we don't have access to KTp::Contact and have avatars only from the last cache recreation (that means that when you go offline, half of your contacts suddenly loose avatars). This patch now reloads the cache for the account that went offline (second part of this patch is that I've modified the cache to update the database on avatar data change, so for each contact coming online the avatar gets stored in the cache). But as the contact may have not came online during the last connection, it now also loads the avatars from the config file if the database has nothing (this matches the KTp::Contact behavior).
>
>
> Diffs
> -----
>
> kpeople/datasourceplugin/CMakeLists.txt 8068977
> kpeople/datasourceplugin/im-persons-data-source.cpp f0868b8
>
> Diff: https://git.reviewboard.kde.org/r/122444/diff/
>
>
> Testing
> -------
>
> I go offline and all my contacts keep their avatars.
>
>
> Thanks,
>
> Martin Klapetek
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-telepathy/attachments/20150208/d5273be5/attachment.html>
More information about the KDE-Telepathy
mailing list