Re: MaildirQueue
[email protected] (Jason R. Mastaler)
| Newsgroups | gmane.mail.spam.tmda.devel |
|---|---|
| Message-ID | <[email protected]> |
[email protected] (Jason R. Mastaler) writes: > The other question - to lock or not to lock? After thinking about this some more, I don't think locking will be necessary. TMDA delivers to pending/new, and doesn't write to or rename messages to pending/cur, so there shouldn't be any write conflicts with MUAs (who rename messages they read to pending/cur). The only issue is the case where TMDA is looking for a confirmed message in pending at the same time a MUA is moving it from new/ to cur/ and renaming it. There exists the possibility for TMDA to think that the message is not there, thus returning a bounce (ACTION_MISSING_PENDING). I think this can be handled by doing a small loop and retrying multiple times before giving up and determining the message is *really* not there. Since this is a rare case, the extra computational expense can be justified.