Review Request 116707: KTp KDED Module: Implemented groups caching.

David Edmundson david at davidedmundson.co.uk
Wed Apr 2 12:59:58 UTC 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/116707/#review54876
-----------------------------------------------------------


Sorry for the super late review.


contact-cache.cpp
<https://git.reviewboard.kde.org/r/116707/#comment38322>

    This is theoretically a bit slow.
    
    I'm leaning towards taking this towards doing it fully normalised. 
    
    i.e
    
    contactGroups:
    accountId*, contactId*, groupId
    
    groups:
    groupId*, groupName
    
    I don't think it would be any more code as you'd then simplify a lot. I think our efforts to keep things simple end up in code that's actually harder to comprehend.
    
    These 10 lines would become just:
    db.exec("DELETE FROM groups where groupId NOT IN (SELECT DISTINCT(groupId) FROM  contactGroups)")
    
    then we don't need to keep a weird map in memory with potential null values and askIdForGroup becomes simpler too.


- David Edmundson


On March 14, 2014, 10:35 a.m., Alexandr Akulich wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/116707/
> -----------------------------------------------------------
> 
> (Updated March 14, 2014, 10:35 a.m.)
> 
> 
> Review request for Telepathy.
> 
> 
> Repository: ktp-kded-module
> 
> 
> Description
> -------
> 
> Implemented in most simple and short way. I hope, there is no significant flaws.
> 
> 
> Diffs
> -----
> 
>   contact-cache.h 8fa6fac 
>   contact-cache.cpp 47fe0cd 
> 
> Diff: https://git.reviewboard.kde.org/r/116707/diff/
> 
> 
> Testing
> -------
> 
> Working good.
> 
> 
> Thanks,
> 
> Alexandr Akulich
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-telepathy/attachments/20140402/081e8d43/attachment.html>


More information about the KDE-Telepathy mailing list