<table><tr><td style="">dvratil created this revision.<br />Herald added a project: KDE PIM.<br />Herald added a subscriber: kde-pim.<br />dvratil requested review of this revision.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D21455">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>Introduce a recovery codepath when Multiple Merge Candidates error<br />
occurs during Item merging. Since clients generally do not use<br />
merging, this really only happens during ItemSync. In such case we<br />
quitely delete all the conflicting items from the database and reschedule<br />
the collection sync. The next sync should then succeed and bring the<br />
collection into a consistent state.</p>
<p>Note that this does not fix the Multiple Merge Candidates bug - it can<br />
still happen (and we still don't know how), but Akonadi should now be<br />
able to recover from it automatically without user intervention, thus<br />
making this issue less of a PITA.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Successfuly auto-recovered a broken collection on my setup.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R165 Akonadi </div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D21455">https://phabricator.kde.org/D21455</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>autotests/server/fakedatastore.cpp<br />
autotests/server/fakedatastore.h<br />
src/server/handler/itemcreatehandler.cpp<br />
src/server/handler/itemcreatehandler.h<br />
src/server/storage/datastore.cpp<br />
src/server/storage/datastore.h</div></div></div><br /><div><strong>To: </strong>dvratil<br /><strong>Cc: </strong>kde-pim, dvasin, rodsevich, winterz, vkrause, mlaurent, knauss, dvratil<br /></div>