News for hackers. Stuff that matters.
Re:Ten Commandments of How to Write an IMAP Client (2006) by ts4z on Monday October 28, 2019 @06:42AM (#21375762)
Message-ID is not unique per message, or per folder or user. The trivial counterexample is a message that goes through a mailing list may exist from the list and in a Sent folder with the same Message-ID but possibly different content, among other (less convincing) reasons.

A UIDVALIDITY change should blow your whole cache. In practice they are rare.

Re:Ten Commandments of How to Write an IMAP Client (2006) by dqv on Monday October 28, 2019 @07:09AM (#21375887)
>Message-ID is not unique per message

Thank you for saving me from the heartbreak of finding this out later. Seriously you just saved me a ton of time.

>A UIDVALIDITY change should blow your whole cache. In practice they are rare.

So even in a huge pile of mail, everything would have to be reprocessed. Since it's so rare, I'm definitely going to set up metrics to monitor when it does happen. Do you have any insight on how people store the mail? Do they actually use the UID to reference it or is it used as more of a cursor?

Re:Ten Commandments of How to Write an IMAP Client (2006) by ts4z on Monday October 28, 2019 @10:48AM (#21377468)
Most clients want to use UID, and it’s a good key for the same reason a SQL row number is, and inconvenient for servers for the same reason consistent hashing schemes don’t have it. I’m not sure what you mean about a cursor. I’m sure clients use UIDs as cursors. They’re good for that.