Re: [Jmap] draft-ietf-jmap-mdn-06

Bron Gondwana <brong@fastmailteam.com> Thu, 11 June 2020 12:09 UTC

Return-Path: <brong@fastmailteam.com>
X-Original-To: jmap@ietfa.amsl.com
Delivered-To: jmap@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 681753A077A for <jmap@ietfa.amsl.com>; Thu, 11 Jun 2020 05:09:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=fastmailteam.com header.b=pkPgK+u8; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=YAXUkRkf
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id vpgHhnfgb38t for <jmap@ietfa.amsl.com>; Thu, 11 Jun 2020 05:09:47 -0700 (PDT)
Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A01603A0766 for <jmap@ietf.org>; Thu, 11 Jun 2020 05:09:47 -0700 (PDT)
Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id C13CE5C0185 for <jmap@ietf.org>; Thu, 11 Jun 2020 08:09:46 -0400 (EDT)
Received: from imap7 ([10.202.2.57]) by compute1.internal (MEProxy); Thu, 11 Jun 2020 08:09:46 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= fastmailteam.com; h=mime-version:message-id:in-reply-to :references:date:from:to:subject:content-type; s=fm2; bh=tV+wZfQ v6Rkb6HZC1+lr8L2RulwMB9KURofFNZWFn1E=; b=pkPgK+u8lfmpucmjqTWjXj5 lnrwAf4x2PZ0ord0puh2mHBI3XetSgU8TgzgM8UnE3z01x2g3vGhSXcunuFtkXty Fyp/7VXEhioOA80VsDleE51FK5MQyKk1ra+l+iqskzycV6o2JmQecNBk5pCGaG/O psZvtyND5+auKdcpFIQZjLPEmq5j8jQLw+SgMPzHsqHwdq1jgNoKj83ZPT6pePkM 3mp9cqE0aSZ7SPH3K1VhpXj6RBHxawhraKkcom9FwI2zJlb7xLnY+A0xhiWlkfaU oVl4wItmIupcEZSjKPFLsKut4P1XS775Xe0hppD+bDUNY9vbOkDEZyj9CyNjy9A= =
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=tV+wZf Qv6Rkb6HZC1+lr8L2RulwMB9KURofFNZWFn1E=; b=YAXUkRkf4HhRgoDJC3RoyE ocIYgyyTox6GpiSX4DB9gCHG2ttoEFTCADuiClbaFoOljAIzGKVb8/TP7Xx2BZbQ KC6IcjJ/ZF8f6m/UZiletgIJUoOg8elMTgsloPvjZCNGZUa/pkjDxLC10spxt5zM ylF1kp4N0FU81lrqwRgZloJwlhtKdUk62paHozzcTxGSP/CdNgmQZ9anxptubbvI Qtseca7Q5UUlNotLUfzfO45P12eX5CE+05WFn04PGe/jlFyJnYQN/wW4zLcSCbze CKgjBWEir+iFgzCkiPoIVxTQG6IrHVG/xR8eIZwrAmteXg4RGXL8V1Cb1EsPlPJA ==
X-ME-Sender: <xms:Ch_iXuN4DU8xYVSf1iRX9wyZDefQceu4qRKvUR_xKbjtYf6_fFaStQ>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudehledgvddvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefofgggkfgjfhffhffvufgtsegrtd erreerredtnecuhfhrohhmpedfuehrohhnucfiohhnugifrghnrgdfuceosghrohhnghes fhgrshhtmhgrihhlthgvrghmrdgtohhmqeenucggtffrrghtthgvrhhnpefhudfhveehve dvleehvedtvdehkeetiefffeeluefgfeffuedviefgjeeuuefghfenucffohhmrghinhep lhhinhgrghhorhgrrdgtohhmnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpe hmrghilhhfrhhomhepsghrohhnghesfhgrshhtmhgrihhlthgvrghmrdgtohhm
X-ME-Proxy: <xmx:Ch_iXs-GklaV0bw8WB5IoajR5QopXhr4UR6uKpWTzChlO4FrfT5WMw> <xmx:Ch_iXlS4tUHeMoW6HOvNlLs3t8aKA2Hl2svFSdaI9EyaPqaWgibsMw> <xmx:Ch_iXutfTkjbsQHEfAYSDoKbJhrTNG1p77Iyr3fPokOMXkdo0Li4fA> <xmx:Ch_iXl8-XadpthmyPUImpZ9XLifa0pvv5hdx0UULbg4_ySglaf0jnA>
Received: by mailuser.nyi.internal (Postfix, from userid 501) id 4040C180091; Thu, 11 Jun 2020 08:09:46 -0400 (EDT)
X-Mailer: MessagingEngine.com Webmail Interface
User-Agent: Cyrus-JMAP/3.3.0-dev0-525-ge8fa799-fm-20200609.001-ge8fa7990
Mime-Version: 1.0
Message-Id: <670d3ff0-4aa1-4939-9a15-87e921fac080@dogfood.fastmail.com>
In-Reply-To: <9424bb4b-ea8d-13be-ef72-75b9ce003339@cketti.de>
References: <b5eac159-c58e-dd75-f7f8-73a99b67345d@fastmail.com> <c4a7348f-0a09-19f0-14fd-4162479b4cd4@fastmail.com> <Mime4j.45.b5134222dd4c80fb.170eebd92f8@linagora.com> <ed338838-996a-26ad-3ba6-b5c578155e18@fastmail.com> <Mime4j.56.bf28b98699a28c35.170f24c1a82@linagora.com> <Mime4j.73.6bcc408d91ada72b.170f70b92f4@linagora.com> <Mime4j.49.2de94ecc6101a607.171c12e9c7b@linagora.com> <7e3a193f-6515-4d32-85a0-88bf624ba97c@www.fastmail.com> <050acaf4-05fd-448e-ad64-8313c14f6d23@dogfood.fastmail.com> <6d2919ca-9026-484e-885c-14e8b2bca05e@dogfood.fastmail.com> <9424bb4b-ea8d-13be-ef72-75b9ce003339@cketti.de>
Date: Thu, 11 Jun 2020 22:09:26 +1000
From: Bron Gondwana <brong@fastmailteam.com>
To: jmap@ietf.org
Content-Type: multipart/alternative; boundary="c62eb0a90c6342209c29b9000c5fad04"
Archived-At: <https://mailarchive.ietf.org/arch/msg/jmap/X-c2yEtOzrnOTLB6sIfq3fOZCQE>
Subject: Re: [Jmap] draft-ietf-jmap-mdn-06
X-BeenThere: jmap@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: JSON Message Access Protocol <jmap.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jmap>, <mailto:jmap-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/jmap/>
List-Post: <mailto:jmap@ietf.org>
List-Help: <mailto:jmap-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jmap>, <mailto:jmap-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Jun 2020 12:09:49 -0000

On Thu, Jun 11, 2020, at 20:39, cketti wrote:
> On 10.06.20 14:45, Bron Gondwana wrote:
>>> *3.1 Sending an MDN*
>>> 
>>> The Email/set example is incorrect. Since the implicit request is a patch to "keywords/$mdnsent", a server would not be expected to echo the full value of the keywords property in the result, since it didn't unilaterally change it. I would expect this response:
>>> 
>>>      [ "Email/set", {
       "accountId": "ue150411c",
       "oldState": "23",
       "newState": "42",
       "updated": {
         "Md45b47b4877521042cec0938": {}
       }
     }, "0" ]]
>>> 
>>> 
>>> Where "updated" maps the emailId from the forEmailId property to an empty object.
>>> 
> 

> This would be annoying for clients. They'd have to hard-code what the implicit Email/set looks like.

> It also makes it harder to change what the implicit Email/set call looks like in a future version of the spec. If an additional property was to be modified it would have to be included in the response to be backward compatible to this spec. Then you'd have to come up with a new way to specify an implicit request ("include these changed properties in the response, but not those").

> I do realize that including the modified keyword in the response makes things more complicated for the server. But to me it feels like the better alternative.


The argument of "if an additional property was to be modified" doesn't apply in JMAP land, because that additional property would come with an additional "using" parameter, and the client would have to set that - in which case it would know what the server would do. There's no backwards/forwards compatibility issue because the client explicitly requests which specs are to be used, and the server explicitly lists which ones it supports.

HOWEVER...

You raise pretty much the same objection that I have to implicit sets in the first place. They shouldn't exist. So what would it look like to have an EXPLICIT set?

       [[ "MDN/send", {
         "accountId": "ue150411c",
         "identityId": "I64588216",
         "send": {
           "k1546": {
             "forEmailId": "Md45b47b4877521042cec0938",
             "subject": "Read receipt for: World domination",
             "textBody": "This receipt shows that the email has been
                 displayed on your recipient's computer. There is no
                 guaranty it has been read or understood.",
             "reportingUA": "linagora.com; OpenPaaS",
             "disposition": {
               "actionMode": "manual-action",
               "sendingMode": "MDN-sent-manually",
               "type": "displayed"
             }
           }
         },
*         "onSuccessUpdateEmail": {
           "#k1546": {
             "keywords/$mdnsent": true**
**           }**
**         }*
       }, "0" ]]

This would match the semantics of EmailSubmission/set, which this is kind of a special case of in some ways, and would then mean that there's never any need to worry about the automatic tasks that the server takes, because it never does. Yes, you need to hard-code that logic into clients, but it strongly matches with my hard earned belief that automatic magical behaviour on the server is bad - the client should explicitly ask for side-effects.

I would also put a SHOULD or even MUST in the spec that the server reject an MDN/send which doesn't result in setting the keyword $mdnsent on the server in that case.

But - I'm happy with either way - but I'm not happy with requiring the Email/set response to act differently from every other triggered Email/set response, because as a server author this makes things really messy.

Bron.

--
 Bron Gondwana, CEO, Fastmail Pty Ltd
 brong@fastmailteam.com