One document matched: draft-williams-lwig-api-considerations-00.txt
Individual Submission C. Williams, Ed.
Internet-Draft Consultant
Intended status: Informational March 7, 2011
Expires: September 8, 2011
Light Weight API Implementation Guidance
draft-williams-lwig-api-considerations-00.txt
Abstract
These are a few notes on high-lighting the importance of looking at
Considerations of the Application Programming Interface for Light
Weight IP implementation of the TCP/IP protocol suite.
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 September 8, 2011.
Copyright Notice
Copyright (c) 2011 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.
Williams Expires September 8, 2011 [Page 1]
Internet-Draft LWIG API Considerations March 2011
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . 3
3. Light Weight Application Model . . . . . . . . . . . . . . . . 3
4. A summary of programming interface issues for light-weight
TCP/IP stacks . . . . . . . . . . . . . . . . . . . . . . . . . 4
4.1. Quick look at uIP API model . . . . . . . . . . . . . . . . 5
4.2. Quick look at TinyOS API model . . . . . . . . . . . . . . 5
5. Potential future work . . . . . . . . . . . . . . . . . . . . . 5
6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 5
7. Security Considerations . . . . . . . . . . . . . . . . . . . . 5
8. Summary and Conclusion . . . . . . . . . . . . . . . . . . . . 5
9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 6
9.1. Normative References . . . . . . . . . . . . . . . . . . . 6
9.2. Informative References . . . . . . . . . . . . . . . . . . 6
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 6
Williams Expires September 8, 2011 [Page 2]
Internet-Draft LWIG API Considerations March 2011
1. Introduction
Any Light Weight IP implementation guidance of the TCP/IP protocol
suite must also take into Considerations the Application Programming
Interface. The applications paradigm model on the type of devices
that will run Light Weight TCP/IP stacks is not only different but
the requirements of the interface must also take into account similar
design chooses regarding the available RAM usage.
In addition, it is also the hoped that this discount will focus
attention on the need to incorporate Light-weight IP guidance on the
Application Programming Interface into the TCP/IP stacks.
2. Terminology
Light Weight IP
Light Weight IP is a term that has become a way in which to
describe the light-weight implementation of the TCP/IP protocol
suite. There have been implementations written by international
developers [uIP]. The goal of the such implementations is having
a TCP/IP stack to reduce RAM usage while still having a full scale
TCP. This makes such an implementation useful in small embedded
systems with tens of kikobytes of free RAM.
3. Light Weight Application Model
The IETF has published a 6LOWPAN design and applications document
that has insights that of the expected application scenario space for
6LOWPAN work. The Light Weight Guidance working group is expected to
provide guidance and Considerations in terms of implementation of the
required Light Weight TCP/IP stacks [I-D.ietf-6lowpan-usecases]. To
this end there is a convergence that the types of targeted devices
with light-weight TCP/IP stacks are those systems that are designed
to do some specific task, rather than be a general-purpose computer
for multiple tasks. Requirements of such embedded applications
running on light-weight TCP/IP stacks may be both real-time and
others may have low or no performance requirements. From the already
provided usage scenarios [I-D.ietf-6lowpan-usecases] the primary
focus of work regarding light-weight TCP/IP stacks in terms of their
work in IETF protocol design up to this point is the ability to
communicate is more important than throughput. They will be low-
powered small systems that don't have much data. The low RAM usage
means that there will be low throughput.
Not only will the TCP/IP stack take into consideration these design
Williams Expires September 8, 2011 [Page 3]
Internet-Draft LWIG API Considerations March 2011
objectives but the application programming interface into these
light-weight implementations must also inter-work with the TCP/IP
stack with these contraints in mind. In addition, such applications
require new programming abstractions to support them with these
contraint requirements. The IP/IPv6 Socket API may not be a basis
for the proper programming abstraction whereby an application
programming interface is implemented. For example, a typical
implementation of the IP Socket API will have some variation of a
worker thread that is listening to a TCP socket for incoming traffic,
and buffering the received data for the main thread to access
However, the worker thread also has to do some regular operations
(say, once per second), even if there is no data coming in. In a
very limited memory and low-power device such a programming model
would not work. In addition, this programming model is a general all
purpose model. While there may be a wide and vary range of
applications that run on light-weight TCP/IP stacks, we can reduce
the programming abstraction whereby any one device will not be a
general purpose machine but will be very narrow in the application
running on it.
With this in mind the IP/IPv6 socket API would be overkill in terms
of what would be required by such light-weight TCP/IP stacks. The
range of libraries and other tools would not be loaded on to these
devices as in a general purpose TCP/IP implementation. Instead,
applications running on light-weight TCP/IP stacks would need a way
to simply know that a incoming packet is destined for it and that it
would be able to enough time to process the packet. Such processing
must be done within the contraints of what the underlying light-
weight IP stack provides in terms of packet processing. This means
that all of the kinds of added IP socket options and functionality
may also not be required as part of the programming model. All of
this scaled down application interface doesn't mean that application
inter-workings with general purpose TCP/IP stacks stops working.
The following section discusses some issues and provides a summary
examples.
4. A summary of programming interface issues for light-weight TCP/IP
stacks
As described in the previous section it is clear that Considerations
for a new guidance document on light-weight stack guidance must take
into account the application programming interface. And that the
currently standard defined interfaces such as the IP socket API will
not meet those constrained requirements. Below is a quick survey
look at some of these APIs. It is documented to provide some
insights as to guidance must be part of the light-weight
Williams Expires September 8, 2011 [Page 4]
Internet-Draft LWIG API Considerations March 2011
implementation guidance documentation suite.
4.1. Quick look at uIP API model
The uIP application interface [uIP] uses a model based on an event
driven API. In such a model execution is always initiated by the
light-weight IP stack. In such an event driven model applications
are called by the light-weight IP stack and must always return. The
proposal put forth with uIP is that the multi-threaded nature of the
IP socket API would be overly consuming in terms of RAM [uIP]. In
addition, the processing required would not meet the low-powered
requirements of such devices defined in the 6LOWPAN work.
4.2. Quick look at TinyOS API model
TinyOS is an open-source operating system designed for wireless
embedded sensor networks [TinyOS]. The TinyOS application interface
[TinyOS] uses a model based on an split-phase or non-blockin API. In
such a model execution when the application interface sends a message
the routine would return nearly immediately - even before the actual
message is sent by the TinyOS. TinyOS uses a call-back facility to
notify the application that it was done with sending. With this
programming model it is expected that no code runs for long periods
of time; otherwise, packets may be dropped [TinyOS].
5. Potential future work
What could be done in the IETF
6. IANA Considerations
This document has no requests to IANA.
7. Security Considerations
Add the security aspects here.
8. Summary and Conclusion
It is not just the TCP and IP layers that change with the Light
Weight Implementation of TCP/IP stacks. The application programming
interfaces must change as well. How applications receive, process
and send packets is critical to the Light Weight stacks as well.
This may require the adaption of new programming model taking into
Williams Expires September 8, 2011 [Page 5]
Internet-Draft LWIG API Considerations March 2011
account the application requirements and scenarios that have been put
forth in the IETF already.
This document will continue to be updated and evolve as more input
and survey implementation come forth.
9. References
9.1. Normative References
[I-D.ietf-6lowpan-usecases]
Kim, E., Kaspar, D., Chevrollier, N., and J. Vasseur,
"Design and Application Spaces for 6LoWPANs",
draft-ietf-6lowpan-usecases-09 (work in progress),
January 2011.
9.2. Informative References
[TinyOS] University of California Berkeley, "TinyOS",
<http://docs.tinyos.net/index.php/Main_Page>.
[uIP] Adam Dukel, Swedish Institute of Computer Science, "Adam
Dunkel's uIP",
<http://www.sics.se/~adam/uip/index.php/Main_Page>.
Author's Address
Carl Williams (editor)
Consultant
Palo Alto, CA 94306
USA
Email: carlw@mcsr-labs.org
Williams Expires September 8, 2011 [Page 6]
| PAFTECH AB 2003-2026 | 2026-04-24 07:13:46 |