resource and itemMoved()

Martin Koller kollix at aon.at
Mon Apr 9 18:40:45 BST 2018


On Montag, 9. April 2018 10:09:25 CEST Daniel Vrátil wrote:
> Hi Martin,
> 
> 
> On Saturday, 7 April 2018 14:36:35 CEST Martin Koller wrote:
> > There is the method itemMoved() in a resource.
> > As the name suggest, I assume this is called AFTER the akonadi server
> > already changed the database entries, right ?
> 
> Correct.
> 
> > 
> > What happens when the resource can not finish the real move on the storage ?
> > In my case, maildir, itemMoved() fails due to an already existing file with
> > the same name in the destination folder, and it calls cancelTask().
> > 
> > In which state is the database after this failure ?
> 
> The database is "wrong" for a while, but the email still exists in the maildir 
> in the old location, so in the next sync the email should reappear in the 
> original folder.

it does not ...
 
> > In my case I find in the mySQL db only ONE entry with this remoteId in the
> > final folder. So the mail file is still on disk in my inbox but it's not in
> > the DB.
> 
> That's the expected inconsistency after the move but before the sync.

But I have this inconsistency since weeks (the mail in my inbox is from
March, 14th 2018) and "update folder", restart of akonadi, etc. does not change that.

The situation is, the one file is in the final folder, and the DB has the information
that it's in the final folder, but the same filename is also in the inbox but no
entry in the DB tells that.

What I do see is in the target folder is: this exact mail is shown HUNDREDS of times
in kmail! I have no idea why, since this entry is only once in the DB (but I have
1036 rows with a NULL remoteId ... don't know if that is related.


-- 
Best regards/Schöne Grüße

Martin
A: Because it breaks the logical sequence of discussion
Q: Why is top posting bad?

()  ascii ribbon campaign - against html e-mail 
/\                        - against proprietary attachments

Geschenkideen, Accessoires, Seifen, Kulinarisches: www.lillehus.at





More information about the kde-pim mailing list