Re: [core] RFC 7967 (No-Response) together with block-wise transfers in CoAP

Fredrik Wegelid <fredrik.wegelid@wittra.se> Thu, 27 June 2019 13:23 UTC

Return-Path: <fredrik.wegelid@wittra.se>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id AC0D212013C for <core@ietfa.amsl.com>; Thu, 27 Jun 2019 06:23:05 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.998
X-Spam-Level:
X-Spam-Status: No, score=-1.998 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=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=wittra.se
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 5a0KwlbYIX4g for <core@ietfa.amsl.com>; Thu, 27 Jun 2019 06:23:01 -0700 (PDT)
Received: from mail-lj1-x22d.google.com (mail-lj1-x22d.google.com [IPv6:2a00:1450:4864:20::22d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 4A1D9120043 for <core@ietf.org>; Thu, 27 Jun 2019 06:23:00 -0700 (PDT)
Received: by mail-lj1-x22d.google.com with SMTP id 205so2319333ljj.8 for <core@ietf.org>; Thu, 27 Jun 2019 06:23:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wittra.se; s=google; h=mime-version:subject:from:in-reply-to:date:cc:message-id:references :to; bh=RJ5j7UBAofeViAVNX2BmjURZdZFEf5i+5+vHeYN/dao=; b=U+WuGX23C72FZtI2HDJVhgim9SP52CklRaD6/uPCxqT/NaS7+wDKQYb9EcmRZVcA2v Mq2PYgTKTUUnHgoDIQXyvmDvGPh1caMD1/NvTXvVXzwIgJFPLMhoOWxfBR+YpeyhlUuJ bxWXGCjg2LPKZ7l/C8uoxAr6CWUPb1BdNxZEyYCRq1mC44meVuGs/p7ykxnhRIuLY3Zq 4FUsNMSbpLg6nbeWB365k1wtATI/N/WAwSyB6EMdOXgy4rykrnFrl0PgyQy2/cIdH8TI 74k8feMCPS2s2+fpUSjJ8183laGdlRtwyYvW5YWKfGy/Ty+zSvWxd54DAKhsj3C1OgG2 ANXg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=RJ5j7UBAofeViAVNX2BmjURZdZFEf5i+5+vHeYN/dao=; b=aXaW2r3lMCVV8+yPHxinOMqT8sPJGWo9+Ls7qwkW3Cx2+pdya3hKGoKoi0W/ykC/6J iBs6CAr1/ntSW/VeFPnOhbanGddAyhVh+qQTN9nau5/Sm85YC79J0O06LwEIkdfKhJVM /pILrt8Q6K32e/26xoTxkWJK8Cu9130W+vDpeP4W6UwSC2SXKOC+acrAaxEGGsm1p7sR SfhOkDChVdackjjHPmeib0iMNgpMsfBXWgS4t7QrI1pODAEwh6cjvDpg1d0WMIpGDGHL VoSincM8QnArnIF6YMEe9FiPd52u1PEgCHJ9pJuqsIOTUc3FZT/3uNhmn6dnlGhxERMS JB7A==
X-Gm-Message-State: APjAAAXNJupOAG1huSFhUOgQtAKlTajL+IJfeDIjAcfpzvdFfolOFftJ ewskc+vnuIXRmzhiBHA4YMoE5g==
X-Google-Smtp-Source: APXvYqzQVgpCuydKFU6IAdp2vDr2Xu3XUujjZIvvklIeI3E/P/cEs3+e/bLt0lTYh+mF69utAe73eQ==
X-Received: by 2002:a2e:9758:: with SMTP id f24mr2673106ljj.58.1561641778927; Thu, 27 Jun 2019 06:22:58 -0700 (PDT)
Received: from [192.168.0.172] (2.70.105.0.mobile.tre.se. [2.70.105.0]) by smtp.gmail.com with ESMTPSA id s1sm441234ljd.83.2019.06.27.06.22.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 27 Jun 2019 06:22:58 -0700 (PDT)
Content-Type: multipart/alternative; boundary="Apple-Mail=_97E353D9-7832-4D4C-A8AA-2683D11E7279"
Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\))
From: Fredrik Wegelid <fredrik.wegelid@wittra.se>
X-Priority: 3 (Normal)
In-Reply-To: <OF6FE7EA39.5EF1BA5F-ON65258426.001AC7FC-65258426.001D278F@tcs.com>
Date: Thu, 27 Jun 2019 15:22:55 +0200
Cc: core <core@ietf.org>
Message-Id: <F721D71C-66C1-4494-AC80-D1605115E02D@wittra.se>
References: <33FF3DB7-076E-4A2A-BF64-9240406D1927@wittra.se> <95486C6F-A08A-487E-974B-5692D474C06B@wittra.se> <135E11E6-07C7-471B-B2F9-94F875191199@tzi.org> <OF6FE7EA39.5EF1BA5F-ON65258426.001AC7FC-65258426.001D278F@tcs.com>
To: Abhijan Bhattacharyya <abhijan.bhattacharyya@tcs.com>
X-Mailer: Apple Mail (2.3445.104.11)
Archived-At: <https://mailarchive.ietf.org/arch/msg/core/hNGkoX5PSX8B66Q_B8Z3-rtPXrk>
Subject: Re: [core] RFC 7967 (No-Response) together with block-wise transfers in CoAP
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/core/>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 27 Jun 2019 13:23:06 -0000

Hi Abhijan,

Thank you for your response. It is great to see how engaged you guys are :)

The reason that we are talking about this solution are the requirements for the devices in our network. We have devices sending messages (that are big enough to require a blockwise transfer) that have very high requirements when it comes to battery consumption. In order to listen for responses the devices have to keep the radio turned on to listen for these responses. By not listening to the responses (except the last one) we can keep the radio turned off for a larger portion of the time and in such a way save battery. This is our reasoning for wanting to use No-Response together with blockwise.

I understand that from a network perspective this does not really make sense. To reduce the amount of traffic on the network I agree that it would be better to listen for the 2.31 Continue responses and restart the blockwise transfer in the case of a lost block. If we do not have to listen to these responses we could hopefully reduce the power consumption of the device.

BR,
Fredrik

> On 27 Jun 2019, at 07:18, Abhijan Bhattacharyya <abhijan.bhattacharyya@tcs.com> wrote:
> 
> Hi Fredrick and Carsten,
> Thanks for the discussion so far. Let me put my thoughts.
> 
> The proposal to reduce the traffic in case of block-wise transfer using no-response is obvious. However, there is a catch. As per my understanding, the use case considered for block-wise transfer relates to transfers demanding high integrity of the received data and very low complexity at the receiving end in re-assembling the segments. One example is firmware upgrade of remote sensors: you cannot miss a single bit. Also, the message reception is tightly sequential in order. In case you miss one segment or receive in out-of-order, the transfers seizes in between.
> 
> Now, Fredrick, coming to your solution: I do not know the QoS requirements in your perceived use case. You do not care about responses of intermediate blocks (essentially this means RESTfully fire-and-forget!) and you take the response of the last block to ensure the end of transfer. Now the question is, if you care for all the blocks at the receiving end (for which you did not care for a response) how do you ensure reception of all the blocks? Considering the resource constrains in IoT use cases it will be a wastage of bandwidth if you have sent all the segments from the transmit end and the receiver, after receiving the end block, realizes that one intermediate segment got missing. The whole transfer, and the resource consumption related to that, becomes useless. You might have rather stopped at the loss instance and take corrective measures to resume. That would save your resources. So, there something more to think and design carefully according to the exact QoS requirements of the perceived class of use-cases.
> 
> However, in case you are looking for real-time + low-latency + low-resource consuming transfer, you may please have a look at this proposal that we already submitted few months back: https://tools.ietf.org/html/draft-bhattacharyya-core-a-realist-02 <https://tools.ietf.org/html/draft-bhattacharyya-core-a-realist-02> . To relate this draft to your problem you may simply consider to model your block-wise traffic as a time-series traffic.
> 
> Having said that, I did once nurture some ideas to make block-wise transfer "statistically" more resource-efficient, yet reliable . But, must I be confirmed about the efficacy of my idea, both theoretically and experimentally, before I speak about that. I have kept that in back burner. In case there is enough interest I can renew the interest and discuss.
> 
> Thank you.     
> 
> With Best Regards
> Abhijan Bhattacharyya
> Consultant / Scientist,
> {Internet Protocols | 5G | Standardization}, 
> TCS Research,
> Tata Consultancy Services
> Building 1B,Ecospace
> Plot -  IIF/12 ,New Town, Rajarhat,
> Kolkata - 700160,West Bengal
> India
> Ph:- +91 33 66884691
> Cell:- +919830468972 | +918583875003
> Mailto: abhijan.bhattacharyya@tcs.com <mailto:abhijan.bhattacharyya@tcs.com>
> Website: http://www.tcs.com <http://www.tcs.com/>
> ____________________________________________
> Experience certainty.	IT Services
> Business Solutions
> Consulting
> ____________________________________________
> 
> 
> -----"core" <core-bounces@ietf.org <mailto:core-bounces@ietf.org>> wrote: -----
> To: Carsten Bormann <cabo@tzi.org <mailto:cabo@tzi.org>>
> From: Fredrik Wegelid 
> Sent by: "core" 
> Date: 06/26/2019 05:28PM
> Cc: core <core@ietf.org <mailto:core@ietf.org>>
> Subject: Re: [core] RFC 7967 (No-Response) together with block-wise transfers in CoAP
> 
> "External email. Open with Caution"
> 
> Hi Carsten,
> 
> This is how an example looks like without the No-Response option.
> 
> Client -> Server: NON POST Payload: “Block 1...”
> Server -> Client:	NON 2.31 Continue
> Client -> Server: NON POST Payload: “Block 2...”
> Server -> Client:	NON 2.31 Continue
> 
> More blocks…
> 
> Client -> Server: NON POST Payload: “Final block...”
> Server -> Client:	NON 2.01 Created (As an example)
> 
> With the No-Response option I wish the exchange to look something like this:
> 
> Client -> Server: NON POST (No-Response:26) Payload: “Block 1...”
> Client -> Server: NON POST (No-Response:26) Payload: “Block 2...”
> 
> More blocks…
> 
> Client -> Server: NON POST Payload: “Final block...”
> Server -> Client:	NON 2.01 Created (As an example)
> 
> This would mean that the server would not send the 2.31 responses for each block (as the No-Response option is set to 26) while it still would send the final response (since the final block does not have the No-Response option set).
> This allows the client to ensure that all blocks were sent successfully. If they are not, the server would respond with another code. It would also mean that the amount of traffic on the network is reduced.
> 
> Best regards,
> Fredrik
> 
> > On 26 Jun 2019, at 13:43, Carsten Bormann <cabo@tzi.org <mailto:cabo@tzi.org>> wrote:
> > 
> > Hi Fredrik,
> > 
> > I’m not sure I entirely understand the message exchanges you envision; maybe you can provide an example.
> > 
> > RFC 7967 has a way to suppress responses based on the response code.
> > Unfortunately, the granularity is on the class only at the moment.
> > The option that carries this information isn’t explicitly defined as an extension point.  Still, someone (the original author?  The WG?) might want to go ahead, e.g., by defining a bit in the option value that says “Not interested in 2.31 responses”.  (Maybe we want to understand what exactly a client would not be interested in a bit more before we go ahead allocating bits like this.)
> > 
> > Abhijan, what do you think?
> > 
> > Grüße, Carsten
> > 
> > 
> >> On Jun 26, 2019, at 13:30, Fredrik Wegelid <fredrik.wegelid@wittra.se <mailto:fredrik.wegelid@wittra.se>> wrote:
> >> 
> >> Hi,
> >> 
> >> I hope that I am using this email list in the correct way. I apologise if that is not the case.
> >> I have some questions/thoughts about using the No-Response option (RFC 7967) together with block-wise transfers in COAP.
> >> 
> >> In my team we are using CoAP to send messages from devices to a server. The messages are of such a size that we need to make block-wise transfers. In an attempt to reduce the amount of traffic in the network we have looked at using the No-Response option. We are however not clear on how this would work if used together with block-wise transfers. We would like to use the No-Response option to make the server omit the 2.31 Continue responses from the server on each block. We would however still like to be able to get a response on the last block to indicate the status of the entire block sequence. 
> >> 
> >> Does this make sense? In RFC 7967 block-wise transfers are not mentioned. Are they meant to be used together?
> >> 
> >> Best regards,
> >> Fredrik Wegelid
> >> _______________________________________________
> >> core mailing list
> >> core@ietf.org <mailto:core@ietf.org>
> >> https://www.ietf.org/mailman/listinfo/core <https://www.ietf.org/mailman/listinfo/core>
> >> 
> > 
> 
> _______________________________________________
> core mailing list
> core@ietf.org <mailto:core@ietf.org>
> https://www.ietf.org/mailman/listinfo/core <https://www.ietf.org/mailman/listinfo/core>
> =====-----=====-----=====
> Notice: The information contained in this e-mail
> message and/or attachments to it may contain 
> confidential or privileged information. If you are 
> not the intended recipient, any dissemination, use, 
> review, distribution, printing or copying of the 
> information contained in this e-mail message 
> and/or attachments to it are strictly prohibited. If 
> you have received this communication in error, 
> please notify us by reply e-mail or telephone and 
> immediately and permanently delete the message 
> and any attachments. Thank you
> 
>