<p>Nice. With Message-ID check in the run when UIDVALIDITY changed for a mailbox with say 1000 mails, this would mean:</p>
<ul>
<li>SEARCH the new UIDs (no time overhead against NO Message-ID check)</li>
<li>SEARCH the Message-ID for each UID (+10-25 seconds IMAP side time overhead)</li>
</ul>
<p>Of course, adding Message-ID only is not enough to get a full valid matching with what we have locally: it's possible to have more than one mail with the same Message-ID header and mails without a Message-ID at all. For those, a full re-download might be done.</p>
<p>If we have a few 90% matching, we are saving 900 re-download. This sounds quite good. There would be local time overhead to do all the checks with the local maildir but this would still be good.</p>
<p>This is good optimization for UIDVALIDITY changes.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/OfflineIMAP/offlineimap/issues/190#issuecomment-95916965">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AKFSEG73SbS5EjYHTua4Iz_g9gnCgMZjks5oCi0vgaJpZM4EBVcm.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
<link itemprop="url" href="https://github.com/OfflineIMAP/offlineimap/issues/190#issuecomment-95916965"></link>
<meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>