You should look at the RemoteDelivery sources.
RemoteDelivery stores "serviced" messages in its own SpoolRepository. It
also create "delivery threads" and start them over this repository.
This threads try to deliver messages and if they get temporary failures
they store the message with an "error" state, a counter in the
error_message and update the last_updated field. The "accept" method
used to know what mails to read uses an accept filter that choose what
mails are ready to be sent.
Imho RemoteDelivery is very similar to what you need. Use it as a reference.
Stefano
haipeng du wrote:
My goal is to delay sending email. When one email comes in, I will check if
that mail come from specified email address. If yes, I want to copy this
mail and send to another email address(different one) after 48 hours.
What is the best thing I can do? By now, I just store that kind of mail to
specified folder(for example: user_delay). And I try to use mail repository
to listen that folder and check the life time. If it is olded than 48
hours,
send it out. But after I create such repository object, it can not list
anything. I just guess that because that mails are not store with the same
repository object. Is that correct?
Thanks a lot.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]