-
Notifications
You must be signed in to change notification settings - Fork 168
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Transaction rollbacks can cause mail loss #117
Comments
There is no transaction for each message, unfortunately (see #66), so message was deleted before transaction of message was commited, so data loss is possible IMO. I'm not have the time to work on such a feature, but feel free to submit a PR. |
Django 1.9 has a nice signal: on_commit():
I think the delete on the pop3/imap server should happen in this signal. If things go wrong you import the message twice. That's better than message loss. |
I know how works transaction, but there is some issues with implementations and different backend compatibility to use |
Pull requests are welcome to provide callback from ``Mailbox.get_new_mail` to transports about successful mail save. |
I won't use django-mailbox in the next weeks. I won't provide a pull request. Good bye. |
I want to know if loosing mail can happen.
Maybe like this.
This would result in message lost, since the pop3 server has deleted the mail, but the mail was never entered into the DB since the transaction was rolled back.
The text was updated successfully, but these errors were encountered: