[Bug 62378] Offline contact caching

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Tue Nov 26 17:09:12 PST 2013


https://bugs.freedesktop.org/show_bug.cgi?id=62378

Xavier Claessens <xclaesse at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch

--- Comment #7 from Xavier Claessens <xclaesse at gmail.com> ---
Worked on Gabble implementation, and I changed my mind on how to implement
this. I create one file per contact now, and the CM is responsible to update
the cache when information change (e.g. vcard fetched). This is because gabble
does not keep vcard in memory forever so we cannot wait too long before writing
it on disk, and we can't wait for TpBaseConnection to be disconnected to update
the cache, because at that point it's already too late to request contact
attributes.

I removed client-side TpOfflineContact API for now.

I'm still not entirely happy with the API, it really gives all the
responsability to the CM and I hope to find a way to make it transparent. Also
the code lives in TpBaseContactList but does not really use it... Better ideas
are welcome.

It also doesn't remove contacts from the cache when they are not part of the
roster anymore.

And finally, it does sync disk read/write which is bad™. Writing the cache
async is trivial change, but async read is more problematic because we have to
fill contact attributes syncronously... not sure how to fix that.

Here is new API in tp-glib:
http://cgit.collabora.com/git/user/xclaesse/telepathy-glib.git/log/?h=offline-cache

And implementation in gabble:
http://cgit.collabora.com/git/user/xclaesse/telepathy-gabble.git/log/?h=offline-cache

With those 2 branch we fix an old bug that always annoyed me: offline xmpp
contacts now have an avatar in empathy !

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the telepathy-bugs mailing list