Trần Tiến Đức created JAMES-2663:
------------------------------------
Summary: [WebAdmin DMV Route] Restore API
Key: JAMES-2663
URL: https://issues.apache.org/jira/browse/JAMES-2663
Project: James Server
Issue Type: New Feature
Reporter: Trần Tiến Đức
### Define `Query` object
JSON List of criterion objects, logical AND between criteria.
A criterion looks like this:
{code:java}
{
"field":
"value":
"operator":
}{code}
Possible fields:
- deletionDate date formatted as string (Operation: Before + After)
- deliveryDate date formatted as string (Operation: Before + After)
- recipients list of string (Operator: Contains, ContainsIgnoreCase)
- sender string (Operator: Equals, EqualsIgnoreCase)
- hasAttachment boolean (Operator: Equals)
- originMailboxes list string (Operator Contains)
- subject string (Operator Equals, Contains + Ignore case)
## API proposal
{code:java}
POST /deletedMessages/users/:userId?action=restore
[JSON Query body]
- 201 Success
{"taskId":"12e3"}
- 404 if the user does not exist
- 503 if `DeletedMessagesVault` is not avaiable
{code}
- Create `DeletedMessagesVaultRoutes` class in
`/server/protocols/webadmin-mailbox-deleted-messages-vault`
- Search the `DeletedMessage` with `Flux<DeletedMessage> search(Query)` is
define in MAILBOX-381 then move it to `Restored Emails` mailbox.
- create unit-test to test this API: configuring webAdmin with
`DeletedMessagesVaultRoutes` on top of a memory mbx manager
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]