I was trying to delete a LOT of email messages in one shot from Thunderbird. I selected everything in a folder (>10,000) and then hit DELETE.
I received an IMAP error. It clearly implied a limitation to just how many UIDS I can submit on an IMAP request at a time.
Is this a limitation of dovecot? (I'm assuming it is).
I can work around this, I think, because I haven't found a limitation to retrieving a list of email message UIDS as yet. I could thereby send splices or chunks of that list of UIDS to delete.
I ran into this while trying to do a variety of obscene things in my attempts to develop a web mail application. Because of the number of strange tests I have, I don't really "blame" anything since I'm not sure that anyone really expects to delete 10,000 messages at one command.