Skip to content
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

Store non-standard message data in UID-independent format #3664

Closed
ChristophWurst opened this issue Sep 28, 2020 · 4 comments
Closed

Store non-standard message data in UID-independent format #3664

ChristophWurst opened this issue Sep 28, 2020 · 4 comments

Comments

@ChristophWurst
Copy link
Member

Feature Request

We store message info locally since #2064. As of #2796 we store a non-standard important flag in the cache table. The problem is that we lose the info in many cases. Like when a message is moved from the INBOX to the archive or the sent mailbox, the message technically vanishes in one mailbox and is found as new in the other. There is currently no mechanism to detect this move. Even if we did it manually, like move, sync and update the cache manually, this wouldn't solve the problem of other IMAP clients (e.g. mobile) doing the move where we have no control over the process.

The best solution I can come up with right now would be to have an extension table, that is, another table just for the non-standard flags. As identifier we can then use the MessageId as that is supposed to be unique. We can then join the tables to get our logical representation of what properties a message has. And if a message is moved and shows up in a new Mailbox, we can still link the two together.

This will also help with #2048, which requires a non-standard flag to be stored in the database.

Summary

Create a table that extends mail_messages and link them via the message ID.

@ChristophWurst
Copy link
Member Author

@miaulalala this is the case now, isn't it?

@miaulalala
Copy link
Contributor

How do you mean, if this is still the case?

@ChristophWurst
Copy link
Member Author

As of #2796 we store a non-standard important flag in the cache table.

The important flag is now always on IMAP or our tags table. So when you drop the cache there is no more non-standard information lost, right?

@ChristophWurst
Copy link
Member Author

Still the case = we store that information now in UID-independent format -> oc_mail_message_tags

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants