[Kde-pim] Calling cancelTask() in ResourceBase::itemAdded()

Grégory Oestreicher greg at kamago.net
Tue Nov 29 07:55:15 GMT 2011


Hi All,

I just got a report for a bug in the Dav resource (bug 287704 - 
https://bugs.kde.org/show_bug.cgi?id=287704) and it seems to me that either I 
misunderstood how the resources should handle errors or Akonadi does not 
recover properly in this case.

The issue here is that if there's a problem in ResourceBase::itemAdded() the 
Dav resource calls cancelTask(), and a quick check showed that the IMAP 
resource does the same. As such changeCommitted() is never called. However 
Akonadi never retries to add the item, while I thought it would.

My question is thus: should these errors be handled by the resources, or 
should Akonadi retry periodically to add these items that provoked an error? 
Another possibility is that I'm misusing cancelTask() and should use another 
method, but can't find which; deferTask() doesn't seem to cut it as it would 
retry eventually too often.

Cheers,
Grégory
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list