maxage causes loss of local email

Janna Martl janna.martl109 at gmail.com
Fri Mar 20 20:18:26 GMT 2015


On Thu, Mar 19, 2015 at 04:31:41PM +0100, Nicolas Sebrecht wrote:
> Let's revamp the strategy, again (I know, I'm a pain).
> 
> Instead, we could request the remote side ONCE for all for UIDs in
> (maxage +n), take the lowest UID from this set and request the other
> side for all the UIDs bigger than lowest_UID and sync, period.
> 
> 1. Request remote with (maxage + n); remote.messageslist won't change.
> 2. Find the lowest_UID in remote.messageslist.
> 3. Request local for UIDs greater than lowest_UID; we have local.messageslist.
> 4. Sync remote.messageslist against local.messageslist.

OK, this is clearly a lot better. See the patch I sent. (I was also
unhappy about the other one, because it was hard to even state what
its behavior was.)

I did notice another issue, though -- quickchanged (the -q option)
doesn't do any good if you're using maxage. I left this alone for now;
the problem is that the "quick" method of seeing whether an IMAP
folder has changed involves getting a list of all the message
sequences numbers, and checking if that has the same number of items
as the statusfolder. If we're using maxage, the statusfolder only
contains recent messages, so we somehow want to reduce this message
sequence # list to recent messages, but it takes longer (another IMAP
operation) to convert these into UIDs (or get dates from them). I
don't really have any ideas...

-- J.M.




More information about the OfflineIMAP-project mailing list