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 importance flag on IMAP, if possible #3069

Closed
ChristophWurst opened this issue May 7, 2020 · 4 comments · Fixed by #4593
Closed

Store importance flag on IMAP, if possible #3069

ChristophWurst opened this issue May 7, 2020 · 4 comments · Fixed by #4593

Comments

@ChristophWurst
Copy link
Member

ChristophWurst commented May 7, 2020

Feature Request

Since #2796 a user can mark messages as important. To make this feature more useful and to improve the integration with other clients (or just another Nextcloud Mail with the same IMAP account), it would be best if we could store the importance flag on IMAP as well. Right now this is only stored in the local cache. This, in turn, means that on a UID change we currently lose these flags. This can be improved in the future with something like a temporary storage and mapping back based on message-ids, but that requires additional work.

Ref https://superuser.com/a/504078/258408
Ref https://tools.ietf.org/html/rfc3501#section-2.3.2
Ref https://tools.ietf.org/html/rfc3501#section-7.1
Ref https://www.rfc-editor.org/rfc/rfc8457.html

Summary

Store the importance flag as IMAP keyword if possible.

@ChristophWurst
Copy link
Member Author

the only two practical things to do is

  • custom keyword.
    • upside: we could be interoperable when the account is confiugred on more than one nextcloud instance, as well as other IMAP clients
    • downside: it's not supported on all IMAP servers
  • a separate table with a mapping of the message-id to the flag
    • downside: possibly the performance as it requires an additional join for every operation on the messages table. but it should be possible. and I'm not 100% if all IMAP messages have a truly unique message-id
    • downside: works only one one instance, not interoperable with other clients

@jancborchardt
Copy link
Member

the only two practical things to do

If we think about doing both, that would leave these downsides:

  • possible performance impact
  • if the IMAP server does not support custom keywords, it will not work on non-Nextcloud mail clients

Seeing how point 2 is already the case for the custom keyword anyway and it’s not fixed by the separate table, it makes sense to go with the custom keyword only, and the separate table brings little benefit, right?

@ChristophWurst
Copy link
Member Author

Seeing how point 2 is already the case for the custom keyword anyway and it’s not fixed by the separate table, it makes sense to go with the custom keyword only, and the separate table brings little benefit, right?

I don't get this. We do not have a separate table for this right now. And we can use the custom keyword on only a few IMAP servers.

If we think about doing both, that would leave these downsides

Sure, just that it's a lot of work. This will generally not happen anytime soon.

@ChristophWurst
Copy link
Member Author

Related proposal: #3664

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

Successfully merging a pull request may close this issue.

3 participants