Akonadi: what should trigger fetching the full payload on new items resource-side?

Friedrich W. H. Kossebau kossebau at kde.org
Fri Sep 24 13:14:49 BST 2021


Hi,

(cc: Daniel, having happily seen he might again have some spare resources for 
Akonadi? :) )

I found the following currently broken in Akonadi:

given a client monitoring items with a fetchscope with fullPayload, when a 
resource is bringing in a new collection with items in it and calling 
ResourceBase::synchronize() to make that known, currently nothing triggers the 
fetching of the payload into the server and thus the clients, so ETM e.g. 
filters them out.

Example:
Add "Personal Contacts" with existing vcf files in ~/.local/share/contacts/. 
The contacts will not be displayed at current runtime, only after a restart of 
Akonadi and its clients, which seems to trigger some re-synchronization (not 
yet researched).

Now I wonder what logic in the current design should ensure and how that the 
payload is actually also pulled when a new item is created in the server and 
there are monitors subscribed which want the full payload.

I have spent some time already trying to understand the mechanisms (see also 
open MRs 71, 72, 76, 77 at https://invent.kde.org/pim/akonadi/-/merge_requests 
for things stumbled over during that), but any ideas how to fix it are 
currently impeded by a lack of full clue about the basic ideas behind the 
current Akonadi syncing designs.

E.g. should the ItemCreateHandler in the server already ensure that also the 
full payload is fetched during its own protocol, when there are subscriptions 
for that known to the NotificationManager?
Or should it be something in the subscription notification server-side, only 
once the whole batch of new raw items is added?
Or (unexpectedly) actually still something to be done by the client(s)?

Cheers
Friedrich




More information about the kde-pim mailing list