D5652: don't CreateItem when the item is known to be already in the DB. Use ModifyItem instead.

Martin Koller noreply at phabricator.kde.org
Sat Apr 29 13:06:14 BST 2017


mkoller created this revision.
Restricted Application added a project: KDE PIM.
Restricted Application added a subscriber: KDE PIM.

REVISION SUMMARY
  To avoid running into the "multiple merge candiate" problem when akonadi searches items by RID and for whatever reason there are really duplicate RIDs, instead when we already have an item ID from the DB, avoid using a Create job at all and answer a fetch with a Modify Job. Akonadi will then query this item by the given id, which is unique and we can never get multiple items in return. 
  Also a query by id is faster since it's indexed.

REPOSITORY
  R165 Akonadi

REVISION DETAIL
  https://phabricator.kde.org/D5652

AFFECTED FILES
  src/agentbase/resourcebase.cpp

To: mkoller, dvratil
Cc: #kde_pim, dvasin, ach, winterz, vkrause, mlaurent, knauss, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20170429/ba50345b/attachment.html>


More information about the kde-pim mailing list