CoAP Implementation Guidance
draft-ietf-lwig-coap-00

The information below is for an old version of the document
Document Type Active Internet-Draft (lwig WG)
Last updated 2014-04-01
Replaces draft-kovatsch-lwig-coap
Stream IETF
Intended RFC status (None)
Formats plain text pdf html bibtex
Stream WG state WG Document
Document shepherd None
IESG IESG state I-D Exists
Consensus Boilerplate Unknown
Telechat date
Responsible AD (None)
Send notices to (None)
LWIG Working Group                                           M. Kovatsch
Internet-Draft                                                ETH Zurich
Intended status: Informational                               O. Bergmann
Expires: October 3, 2014                         Universitaet Bremen TZI
                                                                 E. Dijk
                                                        Philips Research
                                                                   X. He
                                               Hitachi (China) R&D Corp.
                                                         C. Bormann, Ed.
                                                 Universitaet Bremen TZI
                                                          April 01, 2014

                      CoAP Implementation Guidance
                        draft-ietf-lwig-coap-00

Abstract

   The Constrained Application Protocol (CoAP) is designed for resource-
   constrained nodes and networks, e.g., sensor nodes in a low-power
   lossy network (LLN).  Yet to implement this Internet protocol on
   Class 1 devices (i.e., ~ 10 KiB of RAM and ~ 100 KiB of ROM) also
   lightweight implementation techniques are necessary.  This document
   provides lessons learned from implementing CoAP for tiny, battery-
   operated networked embedded systems.  In particular, it provides
   guidance on correct implementation of the CoAP specification
   [I-D.ietf-core-coap], memory optimizations, and customized protocol
   parameters.

Status of This Memo

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at http://datatracker.ietf.org/drafts/current/.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   This Internet-Draft will expire on October 3, 2014.

Kovatsch, et al.         Expires October 3, 2014                [Page 1]
Internet-Draft        CoAP Implementation Guidance            April 2014

Copyright Notice

   Copyright (c) 2014 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of
   publication of this document.  Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document.  Code Components extracted from this document must
   include Simplified BSD License text as described in Section 4.e of
   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   3
   2.  Protocol Implementation . . . . . . . . . . . . . . . . . . .   4
     2.1.  Client/Server Model . . . . . . . . . . . . . . . . . . .   4
     2.2.  Message Processing  . . . . . . . . . . . . . . . . . . .   5
       2.2.1.  On-the-fly Processing . . . . . . . . . . . . . . . .   5
       2.2.2.  Internal Data Structure . . . . . . . . . . . . . . .   6
     2.3.  Duplicate Rejection . . . . . . . . . . . . . . . . . . .   6
     2.4.  Token Usage . . . . . . . . . . . . . . . . . . . . . . .   7
       2.4.1.  Tokens for Observe  . . . . . . . . . . . . . . . . .   7
       2.4.2.  Tokens for Blockwise Transfers  . . . . . . . . . . .   8
     2.5.  Transmission States . . . . . . . . . . . . . . . . . . .   8
       2.5.1.  Request/Response Layer  . . . . . . . . . . . . . . .   9
       2.5.2.  Message Layer . . . . . . . . . . . . . . . . . . . .  10
     2.6.  Out-of-band Information . . . . . . . . . . . . . . . . .  11
     2.7.  Programming Model . . . . . . . . . . . . . . . . . . . .  11
       2.7.1.  Client  . . . . . . . . . . . . . . . . . . . . . . .  12
       2.7.2.  Server  . . . . . . . . . . . . . . . . . . . . . . .  12
   3.  Optimizations . . . . . . . . . . . . . . . . . . . . . . . .  13
     3.1.  Message Buffers . . . . . . . . . . . . . . . . . . . . .  13
     3.2.  Retransmissions . . . . . . . . . . . . . . . . . . . . .  14
     3.3.  Observable Resources  . . . . . . . . . . . . . . . . . .  14
     3.4.  Blockwise Transfers . . . . . . . . . . . . . . . . . . .  15
     3.5.  Deduplication with Sequential MIDs  . . . . . . . . . . .  15
   4.  Alternative Configurations  . . . . . . . . . . . . . . . . .  18
     4.1.  Transmission Parameters . . . . . . . . . . . . . . . . .  18
     4.2.  CoAP over IPv4  . . . . . . . . . . . . . . . . . . . . .  19
Show full document text