Uploaded image for project: 'James Mailbox'
  1. James Mailbox
  2. MAILBOX-381

[DeletedMessagesVault] API (not retention) + Contract + impl on top of MailRepository

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • None
    • None
    • None

    Description

      DeletedMessagesVault is where you store mails after being deleted in `Trash`. It allows to:

      • Store a `DeletedMessage` of an user
      • Delete a `DeletedMessage` stored before by the `MessageId`
      • Search a list of `DeletedMessage` by a `Query`

      The proposal API:

      interface DeletedMessagesVault {
           Mono<Void> append(User user, DeletedMessage deletedMessage);
           Mono<Void> delete(MessageId messageId);
           Flux<DeletedMessage> search(Query query);
       }

      API will be placed in a new maven module `mailbox/plugin/deleted-messages-vault`

      You will also need to define those POJOs

      • DeletedMessage: it wraps a MailboxMessage contents and deleted message metadata:
      • deletion date
      • delivery date
      • recipients
      • sender
      • has attachment
      • origin mailboxes
      • subject (contains, equals / ignore case)
      • Query: this POJO define various search criteria base on list of DeletedMessage metadata.

      About DeletedMessagesVault impl

      By leverage `MailRepository` component you will create your impl ontop of `MailRepository`. At the moment `MailRepository` only supports `store` and `remove`, so you have to:

      • Apply search feature in `MailRepository`
      • `DeletedMessagesVault` impl is intend to use `CassandraMailRepository`, `DeletedMessagesVault` is per-user, and each one points to a specify `MailRepositoryUrl` belong to a specific User.
      • Adapt DeletedMessagesVault impl with `MailRepository` APIs.

      Attachments

        Activity

          People

            Unassigned Unassigned
            trantienduchn Trần Tiến Đức
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: