james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From René Cordier (Jira) <server-...@james.apache.org>
Subject [jira] [Commented] (JAMES-3358) Mailbox/set delete: onDestroyRemoveEmails argument implementation
Date Fri, 21 Aug 2020 02:30:00 GMT

    [ https://issues.apache.org/jira/browse/JAMES-3358?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17181537#comment-17181537
] 

René Cordier commented on JAMES-3358:
-------------------------------------

https://github.com/linagora/james-project/pull/3664 contributed this

> Mailbox/set delete: onDestroyRemoveEmails argument implementation
> -----------------------------------------------------------------
>
>                 Key: JAMES-3358
>                 URL: https://issues.apache.org/jira/browse/JAMES-3358
>             Project: James Server
>          Issue Type: Improvement
>            Reporter: Lan Khuat
>            Priority: Major
>
> Property:  {{*onDestroyRemoveEmails*: Boolean}}
> Determine whether the emails in a mailbox should be removed/destroyed when that mailbox
got destroyed.
>  * SHOULD default to *{{false}}*
>  * If *{{false}}*, any attempt to destroy a Mailbox that still has Emails in it will
be rejected with a \{{mailboxHasEmail}}SetError.
>  * If *{{true}}*, any Emails that were in the Mailbox will be removed from it, and if
in no other Mailboxes, they will be destroyed when the Mailbox is destroyed.
> *Request*
> {code:java}
> {
>    "using": [ "urn:ietf:params:jmap:core", "urn:ietf:params:jmap:mail" ],
>    "methodCalls": [
>        [
>            "Mailbox/set", 
>            {
>                 "accountId": "JMAP-ID",
>                 "ifInState": "123",
>                 "create": null,
>                 "destroy": [ "0001" ],
>                 "onDestroyRemoveEmails": true
>            }
>        ]
>    ]
> }
> {code}
> *Response*
>  
> {code:java}
> {
>    "methodResponses": [
>        [
>            "Mailbox/set", 
>            {
>                 "accountId": "JMAP-ID", // the requested accountId
>                 "oldState": "123",
>                 "newState": "124",
>                 "created": null,
>                 "destroyed": [ "0001" ]
>            }
>        ]
>    ], 
>    "sessionState": "abc"
> }
> {code}
>  *DOD:*
>  Integration tests + proof of email deletion when the property is *{{true}}*
> Proof of reject of the request if the property is *{{false}}* (with emails still present
in the mailbox)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message