draft-ietf-core-interfaces-02.txt | draft-ietf-core-interfaces-03.txt | |||
---|---|---|---|---|
CoRE Z. Shelby | CoRE Z. Shelby | |||
Internet-Draft ARM | Internet-Draft ARM | |||
Intended status: Informational M. Vial | Intended status: Informational M. Vial | |||
Expires: May 13, 2015 Schneider-Electric | Expires: January 7, 2016 Schneider-Electric | |||
November 9, 2014 | M. Koster | |||
ARM | ||||
July 6, 2015 | ||||
CoRE Interfaces | CoRE Interfaces | |||
draft-ietf-core-interfaces-02 | draft-ietf-core-interfaces-03 | |||
Abstract | Abstract | |||
This document defines well-known REST interface descriptions for | This document defines well-known REST interface descriptions for | |||
Batch, Sensor, Parameter and Actuator types for use in contrained web | Batch, Sensor, Parameter and Actuator types for use in contrained web | |||
servers using the CoRE Link Format. A short reference is provided | servers using the CoRE Link Format. A short reference is provided | |||
for each type that can be efficiently included in the interface | for each type that can be efficiently included in the interface | |||
description attribute of the CoRE Link Format. These descriptions | description attribute of the CoRE Link Format. These descriptions | |||
are intended to be for general use in resource designs or for | are intended to be for general use in resource designs or for | |||
inclusion in more specific interface profiles. In addition, this | inclusion in more specific interface profiles. In addition, this | |||
skipping to change at page 1, line 41 | skipping to change at page 1, line 43 | |||
Internet-Drafts are working documents of the Internet Engineering | Internet-Drafts are working documents of the Internet Engineering | |||
Task Force (IETF). Note that other groups may also distribute | Task Force (IETF). Note that other groups may also distribute | |||
working documents as Internet-Drafts. The list of current Internet- | working documents as Internet-Drafts. The list of current Internet- | |||
Drafts is at http://datatracker.ietf.org/drafts/current/. | Drafts is at http://datatracker.ietf.org/drafts/current/. | |||
Internet-Drafts are draft documents valid for a maximum of six months | Internet-Drafts are draft documents valid for a maximum of six months | |||
and may be updated, replaced, or obsoleted by other documents at any | and may be updated, replaced, or obsoleted by other documents at any | |||
time. It is inappropriate to use Internet-Drafts as reference | time. It is inappropriate to use Internet-Drafts as reference | |||
material or to cite them other than as "work in progress." | material or to cite them other than as "work in progress." | |||
This Internet-Draft will expire on May 13, 2015. | This Internet-Draft will expire on January 7, 2016. | |||
Copyright Notice | Copyright Notice | |||
Copyright (c) 2014 IETF Trust and the persons identified as the | Copyright (c) 2015 IETF Trust and the persons identified as the | |||
document authors. All rights reserved. | document authors. All rights reserved. | |||
This document is subject to BCP 78 and the IETF Trust's Legal | This document is subject to BCP 78 and the IETF Trust's Legal | |||
Provisions Relating to IETF Documents | Provisions Relating to IETF Documents | |||
(http://trustee.ietf.org/license-info) in effect on the date of | (http://trustee.ietf.org/license-info) in effect on the date of | |||
publication of this document. Please review these documents | publication of this document. Please review these documents | |||
carefully, as they describe your rights and restrictions with respect | carefully, as they describe your rights and restrictions with respect | |||
to this document. Code Components extracted from this document must | to this document. Code Components extracted from this document must | |||
include Simplified BSD License text as described in Section 4.e of | include Simplified BSD License text as described in Section 4.e of | |||
the Trust Legal Provisions and are provided without warranty as | the Trust Legal Provisions and are provided without warranty as | |||
skipping to change at page 2, line 28 | skipping to change at page 2, line 31 | |||
3.1.1. Path template . . . . . . . . . . . . . . . . . . . . 5 | 3.1.1. Path template . . . . . . . . . . . . . . . . . . . . 5 | |||
3.1.2. Resource Type . . . . . . . . . . . . . . . . . . . . 5 | 3.1.2. Resource Type . . . . . . . . . . . . . . . . . . . . 5 | |||
3.1.3. Interface Description . . . . . . . . . . . . . . . . 5 | 3.1.3. Interface Description . . . . . . . . . . . . . . . . 5 | |||
3.1.4. Data type . . . . . . . . . . . . . . . . . . . . . . 6 | 3.1.4. Data type . . . . . . . . . . . . . . . . . . . . . . 6 | |||
3.2. Discovery . . . . . . . . . . . . . . . . . . . . . . . . 6 | 3.2. Discovery . . . . . . . . . . . . . . . . . . . . . . . . 6 | |||
3.3. Versioning . . . . . . . . . . . . . . . . . . . . . . . . 6 | 3.3. Versioning . . . . . . . . . . . . . . . . . . . . . . . . 6 | |||
4. Bindings . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 | 4. Bindings . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 | |||
4.1. Format . . . . . . . . . . . . . . . . . . . . . . . . . . 7 | 4.1. Format . . . . . . . . . . . . . . . . . . . . . . . . . . 7 | |||
4.2. Binding methods . . . . . . . . . . . . . . . . . . . . . 8 | 4.2. Binding methods . . . . . . . . . . . . . . . . . . . . . 8 | |||
4.3. Binding table . . . . . . . . . . . . . . . . . . . . . . 9 | 4.3. Binding table . . . . . . . . . . . . . . . . . . . . . . 9 | |||
5. Interface Descriptions . . . . . . . . . . . . . . . . . . . . 9 | 5. Interface Descriptions . . . . . . . . . . . . . . . . . . . . 10 | |||
5.1. Link List . . . . . . . . . . . . . . . . . . . . . . . . 11 | 5.1. Link List . . . . . . . . . . . . . . . . . . . . . . . . 11 | |||
5.2. Batch . . . . . . . . . . . . . . . . . . . . . . . . . . 11 | 5.2. Batch . . . . . . . . . . . . . . . . . . . . . . . . . . 11 | |||
5.3. Linked Batch . . . . . . . . . . . . . . . . . . . . . . . 12 | 5.3. Linked Batch . . . . . . . . . . . . . . . . . . . . . . . 12 | |||
5.4. Sensor . . . . . . . . . . . . . . . . . . . . . . . . . . 13 | 5.4. Sensor . . . . . . . . . . . . . . . . . . . . . . . . . . 13 | |||
5.5. Parameter . . . . . . . . . . . . . . . . . . . . . . . . 14 | 5.5. Parameter . . . . . . . . . . . . . . . . . . . . . . . . 14 | |||
5.6. Read-only Parameter . . . . . . . . . . . . . . . . . . . 14 | 5.6. Read-only Parameter . . . . . . . . . . . . . . . . . . . 14 | |||
5.7. Actuator . . . . . . . . . . . . . . . . . . . . . . . . . 15 | 5.7. Actuator . . . . . . . . . . . . . . . . . . . . . . . . . 15 | |||
5.8. Binding . . . . . . . . . . . . . . . . . . . . . . . . . 15 | 5.8. Binding . . . . . . . . . . . . . . . . . . . . . . . . . 15 | |||
5.9. Resource Observation Attributes . . . . . . . . . . . . . 16 | 5.9. Resource Observation Attributes . . . . . . . . . . . . . 16 | |||
5.10. Future Interfaces . . . . . . . . . . . . . . . . . . . . 17 | 5.10. Future Interfaces . . . . . . . . . . . . . . . . . . . . 17 | |||
5.11. WADL Description . . . . . . . . . . . . . . . . . . . . . 17 | 5.11. WADL Description . . . . . . . . . . . . . . . . . . . . . 17 | |||
6. Security Considerations . . . . . . . . . . . . . . . . . . . 21 | 6. Security Considerations . . . . . . . . . . . . . . . . . . . 23 | |||
7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 21 | 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 23 | |||
8. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 21 | 8. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 23 | |||
9. Changelog . . . . . . . . . . . . . . . . . . . . . . . . . . 21 | 9. Changelog . . . . . . . . . . . . . . . . . . . . . . . . . . 23 | |||
10. References . . . . . . . . . . . . . . . . . . . . . . . . . . 22 | 10. References . . . . . . . . . . . . . . . . . . . . . . . . . . 25 | |||
10.1. Normative References . . . . . . . . . . . . . . . . . . . 22 | 10.1. Normative References . . . . . . . . . . . . . . . . . . . 25 | |||
10.2. Informative References . . . . . . . . . . . . . . . . . . 23 | 10.2. Informative References . . . . . . . . . . . . . . . . . . 25 | |||
Appendix A. Profile example . . . . . . . . . . . . . . . . . . . 23 | Appendix A. Profile example . . . . . . . . . . . . . . . . . . . 25 | |||
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 24 | Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 26 | |||
1. Introduction | 1. Introduction | |||
The Constrained RESTful Environments (CoRE) working group aims at | The Constrained RESTful Environments (CoRE) working group aims at | |||
realizing the REST architecture in a suitable form for the most | realizing the REST architecture in a suitable form for the most | |||
constrained nodes (e.g. 8-bit microcontrollers with limited RAM and | constrained nodes (e.g. 8-bit microcontrollers with limited RAM and | |||
ROM) and networks (e.g. 6LoWPAN). CoRE is aimed at machine-to- | ROM) and networks (e.g. 6LoWPAN). CoRE is aimed at machine-to- | |||
machine (M2M) applications such as smart energy and building | machine (M2M) applications such as smart energy and building | |||
automation. | automation. | |||
skipping to change at page 7, line 48 | skipping to change at page 7, line 48 | |||
synchronization exchange along with the conditions that trigger an | synchronization exchange along with the conditions that trigger an | |||
update. This specification defines the attributes below: | update. This specification defines the attributes below: | |||
+--------------------+-----------+------------------+ | +--------------------+-----------+------------------+ | |||
| Attribute | Parameter | Value | | | Attribute | Parameter | Value | | |||
+--------------------+-----------+------------------+ | +--------------------+-----------+------------------+ | |||
| Binding method | bind | xsd:string | | | Binding method | bind | xsd:string | | |||
| Minimum Period (s) | pmin | xsd:integer (>0) | | | Minimum Period (s) | pmin | xsd:integer (>0) | | |||
| Maximum Period (s) | pmax | xsd:integer (>0) | | | Maximum Period (s) | pmax | xsd:integer (>0) | | |||
| Change Step | st | xsd:decimal (>0) | | | Change Step | st | xsd:decimal (>0) | | |||
| Greater Than | gt | xsd:decimal | | ||||
| Less Than | lt | xsd:decimal | | ||||
+--------------------+-----------+------------------+ | +--------------------+-----------+------------------+ | |||
Bind Method: This is the identifier of a binding method which | Bind Method: This is the identifier of a binding method which | |||
defines the rules to synchronize the destination resource. This | defines the rules to synchronize the destination resource. This | |||
attribute is mandatory. | attribute is mandatory. | |||
Minimum Period: When present, the minimum period indicates the | Minimum Period: When present, the minimum period indicates the | |||
minimum time to wait (in seconds) before sending a new | minimum time to wait (in seconds) before sending a new | |||
synchronization message (even if it has changed). In the absence | synchronization message (even if it has changed). In the absence | |||
of this parameter, the minimum period is up to the notifier. | of this parameter, the minimum period is up to the notifier. | |||
skipping to change at page 8, line 28 | skipping to change at page 8, line 28 | |||
period MUST be greater than the minimum period parameter (if | period MUST be greater than the minimum period parameter (if | |||
present). | present). | |||
Change Step: When present, the change step indicates how much the | Change Step: When present, the change step indicates how much the | |||
value of a resource SHOULD change before sending a new | value of a resource SHOULD change before sending a new | |||
notification (compared to the value of the last notification). | notification (compared to the value of the last notification). | |||
This parameter has lower priority than the period parameters, thus | This parameter has lower priority than the period parameters, thus | |||
even if the change step has been fulfilled, the time since the | even if the change step has been fulfilled, the time since the | |||
last notification SHOULD be between pmin and pmax. | last notification SHOULD be between pmin and pmax. | |||
Greater Than: When present, Greater Than indicates the upper limit | ||||
value the resource value SHOULD cross before sending a new | ||||
notification. This parameter has lower priority than the period | ||||
parameters, thus even if the Greater Than limit has been crossed, | ||||
the time since the last notification SHOULD be between pmin and | ||||
pmax. | ||||
Less Than: When present, Less Than indicates the lower limit value | ||||
the resource value SHOULD cross before sending a new notification. | ||||
This parameter has lower priority than the period parameters, thus | ||||
even if the Less Than limit has been crossed, the time since the | ||||
last notification SHOULD be between pmin and pmax. | ||||
4.2. Binding methods | 4.2. Binding methods | |||
A binding method defines the rules to generate the web-transfer | A binding method defines the rules to generate the web-transfer | |||
exchanges that will effectively send content from the source resource | exchanges that will effectively send content from the source resource | |||
to the destination resource. The description of a binding method | to the destination resource. The description of a binding method | |||
must define the following aspects: | must define the following aspects: | |||
Identifier: This is value of the "bind" attribute used to identify | Identifier: This is value of the "bind" attribute used to identify | |||
the method. | the method. | |||
skipping to change at page 9, line 13 | skipping to change at page 9, line 25 | |||
This specification supports 3 binding methods described below. | This specification supports 3 binding methods described below. | |||
Polling: The Polling method consists of sending periodic GET | Polling: The Polling method consists of sending periodic GET | |||
requests from the destination endpoint to the source resource and | requests from the destination endpoint to the source resource and | |||
copying the content to the destination resource. The binding | copying the content to the destination resource. The binding | |||
entry for this method MUST be stored on the destination endpoint. | entry for this method MUST be stored on the destination endpoint. | |||
The destination endpoint MUST ensure that the polling frequency | The destination endpoint MUST ensure that the polling frequency | |||
does not exceed the limits defined by the pmin and pmax attributes | does not exceed the limits defined by the pmin and pmax attributes | |||
of the binding entry. The copying process MAY filter out content | of the binding entry. The copying process MAY filter out content | |||
from the GET requests using value-based conditions (e.g Change | from the GET requests using value-based conditions (e.g Change | |||
Step). | Step, Less Than, Greater Than). | |||
Observe: The Observe method relies on the Publish/Subscribe pattern | Observe: The Observe method relies on the Publish/Subscribe pattern | |||
thus an observation relationship is created between the | thus an observation relationship is created between the | |||
destination endpoint and the source resource. On each | destination endpoint and the source resource. On each | |||
notification the content from the source resource is copied to the | notification the content from the source resource is copied to the | |||
destination resource. The creation of the observation | destination resource. The creation of the observation | |||
relationship requires the CoAP Observation mechanism | relationship requires the CoAP Observation mechanism | |||
[I-D.ietf-core-observe] hence this method is only permitted when | [I-D.ietf-core-observe] hence this method is only permitted when | |||
the resources are made available over CoAP. The binding entry for | the resources are made available over CoAP. The binding entry for | |||
this method MUST be stored on the destination endpoint. The | this method MUST be stored on the destination endpoint. The | |||
binding conditions are mapped as query string parameters (see | binding conditions are mapped as query string parameters (see | |||
Section 5.9). | Section 5.9). | |||
Push: When the Push method is assigned to a binding, the source | Push: When the Push method is assigned to a binding, the source | |||
endpoint sends PUT requests to the destination resource upon | endpoint sends PUT requests to the destination resource when the | |||
change of the source resource. The source endpoint MUST only send | binding condition attributes are satisfied for the source | |||
a notification request if the binding conditions are met. The | resource. The source endpoint MUST only send a notification | |||
binding entry for this method MUST be stored on the source | request if the binding conditions are met. The binding entry for | |||
endpoint. | this method MUST be stored on the source endpoint. | |||
4.3. Binding table | 4.3. Binding table | |||
The binding table is a special resource that gives access to the | The binding table is a special resource that gives access to the | |||
bindings on a endpoint. A binding table resource MUST support the | bindings on a endpoint. A binding table resource MUST support the | |||
Binding interface defined in Section 5.8. A profile SHOULD allow | Binding interface defined in Section 5.8. A profile SHOULD allow | |||
only one resource table per endpoint. | only one resource table per endpoint. | |||
5. Interface Descriptions | 5. Interface Descriptions | |||
skipping to change at page 16, line 40 | skipping to change at page 16, line 40 | |||
its link description SHOULD support these observation parameters. | its link description SHOULD support these observation parameters. | |||
The Change Step parameter can only be supported on resources with an | The Change Step parameter can only be supported on resources with an | |||
atomic numeric value. | atomic numeric value. | |||
These query parameters MUST be treated as resources that are read | These query parameters MUST be treated as resources that are read | |||
using GET and set using PUT, and MUST NOT be included in the Observe | using GET and set using PUT, and MUST NOT be included in the Observe | |||
request. Multiple parameters MAY be set at the same time by | request. Multiple parameters MAY be set at the same time by | |||
including the values in the query string of a PUT. Before being set, | including the values in the query string of a PUT. Before being set, | |||
these parameters have no default value. | these parameters have no default value. | |||
+--------------+----------------+------------------+ | +----------------+------------------+------------------+ | |||
| Resource | Parameter | Data Format | | | Resource | Parameter | Data Format | | |||
+--------------+----------------+------------------+ | +----------------+------------------+------------------+ | |||
| Change Step | /{resource}?st | xsd:decimal (>0) | | | Minimum Period | /{resource}?pmin | xsd:integer (>0) | | |||
| Less Than | /{resource}?lt | xsd:decimal | | | Maximum Period | /{resource}?pmax | xsd:integer (>0) | | |||
| Greater Than | /{resource}?gt | xsd:decimal | | | Change Step | /{resource}?st | xsd:decimal (>0) | | |||
+--------------+----------------+------------------+ | | Less Than | /{resource}?lt | xsd:decimal | | |||
| Greater Than | /{resource}?gt | xsd:decimal | | ||||
+----------------+------------------+------------------+ | ||||
Change Step: When set, the change step indicates how much the value | Minimum Period: When present, the minimum period indicates the | |||
of a resource SHOULD change before sending a new notification | minimum time to wait (in seconds) before sending a new | |||
(compared to the value of the last notification). This parameter | synchronization message (even if it has changed). In the absence | |||
has lower priority than the period parameters, thus even if the | of this parameter, the minimum period is up to the notifier. | |||
change step has been fulfilled, the time since the last | ||||
notification SHOULD be between pmin and pmax. | ||||
Less Than: When set, the value of the resource MUST be less than | Maximum Period: When present, the maximum period indicates the | |||
this parameter in order to send a new notification. This | maximum time in seconds between two consecutive syncronization | |||
parameter has lower priority than the period parameters. | messages (regardless if it has changed). In the absence of this | |||
parameter, the maximum period is up to the notifier. The maximum | ||||
period MUST be greater than the minimum period parameter (if | ||||
present). | ||||
Greater Than: When set, the value of the resource MUST be greater | Change Step: When present, the change step indicates how much the | |||
than this parameter in order to send a new notification. This | value of a resource SHOULD change before sending a new | |||
parameter has lower priority than the period parameters. | notification (compared to the value of the last notification). | |||
This parameter has lower priority than the period parameters, thus | ||||
even if the change step has been fulfilled, the time since the | ||||
last notification SHOULD be between pmin and pmax. | ||||
Greater Than: When present, Greater Than indicates the upper limit | ||||
value the resource value SHOULD cross before sending a new | ||||
notification. This parameter has lower priority than the period | ||||
parameters, thus even if the Greater Than limit has been crossed, | ||||
the time since the last notification SHOULD be between pmin and | ||||
pmax. | ||||
Less Than: When present, Less Than indicates the lower limit value | ||||
the resource value SHOULD cross before sending a new notification. | ||||
This parameter has lower priority than the period parameters, thus | ||||
even if the Less Than limit has been crossed, the time since the | ||||
last notification SHOULD be between pmin and pmax. | ||||
5.10. Future Interfaces | 5.10. Future Interfaces | |||
It is expected that further interface descriptions will be defined in | It is expected that further interface descriptions will be defined in | |||
this and other specifications. Potential interfaces to be considered | this and other specifications. Potential interfaces to be considered | |||
for this specifications include: | for this specifications include: | |||
Collection: This resource would be a container that allows sub- | Collection: This resource would be a container that allows sub- | |||
resources to be added or removed. | resources to be added or removed. | |||
skipping to change at page 17, line 50 | skipping to change at page 18, line 18 | |||
<grammars> | <grammars> | |||
<include href="http://tools.ietf.org/html/draft-jennings-senml"/> | <include href="http://tools.ietf.org/html/draft-jennings-senml"/> | |||
</grammars> | </grammars> | |||
<doc title="CoRE Interfaces"/> | <doc title="CoRE Interfaces"/> | |||
<resource_type id="s"> | <resource_type id="s"> | |||
<doc title="Sensor resource type"/> | <doc title="Sensor resource type"/> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
</resource_type> | </resource_type> | |||
<resource_type id="p"> | <resource_type id="p"> | |||
<doc title="Parameter resource type"/> | <doc title="Parameter resource type"/> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
<method href="#update"/> | <method href="#update"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="rp"> | <resource_type id="rp"> | |||
<doc title="Read-only Parameter resource type"/> | <doc title="Read-only Parameter resource type"/> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
</resource_type> | </resource_type> | |||
<resource_type id="a"> | <resource_type id="a"> | |||
<doc title="Actuator resource type"/> | <doc title="Actuator resource type"/> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
<method href="#update"/> | <method href="#update"/> | |||
<method href="#toggle"/> | <method href="#toggle"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="ll"> | <resource_type id="ll"> | |||
<doc title="Link List type"/></doc> | <doc title="Link List type"/></doc> | |||
<method href="#listLinks"/> | <method href="#listLinks"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="b"> | <resource_type id="b"> | |||
<doc title="Batch of sub-resources type">The methods read, | <doc title="Batch of sub-resources type">The methods read, | |||
observe, update and toggle are applied to each sub- | observe, update and toggle are applied to each sub- | |||
resource of the requested resource that supports it. Mixed | resource of the requested resource that supports it. Mixed | |||
sub-resource types can be supported.</doc> | sub-resource types can be supported.</doc> | |||
skipping to change at page 18, line 37 | skipping to change at page 19, line 16 | |||
<method href="#listLinks"/> | <method href="#listLinks"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="b"> | <resource_type id="b"> | |||
<doc title="Batch of sub-resources type">The methods read, | <doc title="Batch of sub-resources type">The methods read, | |||
observe, update and toggle are applied to each sub- | observe, update and toggle are applied to each sub- | |||
resource of the requested resource that supports it. Mixed | resource of the requested resource that supports it. Mixed | |||
sub-resource types can be supported.</doc> | sub-resource types can be supported.</doc> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
<method href="#update"/> | <method href="#update"/> | |||
<method href="#toggle"/> | <method href="#toggle"/> | |||
<method href="#listLinks"/> | <method href="#listLinks"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="lb"> | <resource_type id="lb"> | |||
<doc title="Linked Batch resource type">. The methods read, | <doc title="Linked Batch resource type">. The methods read, | |||
obervableRead, update and toggle are applied to each linked | obervableRead, update and toggle are applied to each linked | |||
resource of the requested resource that supports it. Mixed | resource of the requested resource that supports it. Mixed | |||
linked resource types can be supported.</doc> | linked resource types can be supported.</doc> | |||
<method href="#read"/> | <method href="#read"/> | |||
<method href="#observe"/> | <method href="#observe"/> | |||
<method href="#observe-cancel"/> | ||||
<method href="#getattr"/> | ||||
<method href="#setattr"/> | ||||
<method href="#update"/> | <method href="#update"/> | |||
<method href="#listLinks"/> | <method href="#listLinks"/> | |||
<method href="#appendLinks"/> | <method href="#appendLinks"/> | |||
<method href="#clearLinks"/> | <method href="#clearLinks"/> | |||
</resource_type> | </resource_type> | |||
<resource_type id="bnd"> | <resource_type id="bnd"> | |||
<doc title="Binding table resource type">A modifiable list of | <doc title="Binding table resource type">A modifiable list of | |||
links. Each link MUST have the relation type "boundTo".</doc> | links. Each link MUST have the relation type "boundTo".</doc> | |||
<method href="#listLinks"/> | <method href="#listLinks"/> | |||
skipping to change at page 19, line 28 | skipping to change at page 20, line 13 | |||
<request> | <request> | |||
</request> | </request> | |||
<response status="200"> | <response status="200"> | |||
<representation mediaType="text/plain"/> | <representation mediaType="text/plain"/> | |||
<representation mediaType="application/senml+exi"/> | <representation mediaType="application/senml+exi"/> | |||
<representation mediaType="application/senml+xml"/> | <representation mediaType="application/senml+xml"/> | |||
<representation mediaType="application/senml+json"/> | <representation mediaType="application/senml+json"/> | |||
</response> | </response> | |||
<response status="2.05"> | <response status="2.05"> | |||
<representation mediaType="text/plain"/> | <representation mediaType="text/plain"/> | |||
<representation mediaType="application/senml+exi"/> | ||||
<representation mediaType="application/senml+exi"/> | ||||
<representation mediaType="application/senml+xml"/> | <representation mediaType="application/senml+xml"/> | |||
<representation mediaType="application/senml+json"/> | <representation mediaType="application/senml+json"/> | |||
</response> | </response> | |||
</method> | </method> | |||
<method id="observe" name="GET"> | <method id="observe" name="GET"> | |||
<doc>Observe the value of a sensor, an actuator or a parameter. | <doc>Observe the value of a sensor, an actuator or a parameter. | |||
Only CoAP supports this method since it requires the CoRE | Only CoAP supports this method since it requires the CoRE | |||
Observe mechanism.</doc> | Observe mechanism.</doc> | |||
<request> | <request> | |||
<param name="pmin" style="query" type="xsd:integer"/> | <param name="observe" style="header" type="xsd:integer"> | |||
<param name="pmax" style="query" type="xsd:integer"/> | <option value = 0/> | |||
<param name="st" style="query" type="xsd:decimal"/> | </param> | |||
</request> | </request> | |||
<response status="2.05"> | <response status="2.05"> | |||
<representation mediaType="text/plain"/> | <representation mediaType="text/plain"/> | |||
<representation mediaType="application/senml+exi"/> | <representation mediaType="application/senml+exi"/> | |||
<representation mediaType="application/senml+xml"/> | <representation mediaType="application/senml+xml"/> | |||
<representation mediaType="application/senml+json"/> | <representation mediaType="application/senml+json"/> | |||
</response> | </response> | |||
</method> | </method> | |||
<method id="observe-cancel" name="GET"> | ||||
<doc>Cancel observation in progress. | ||||
Only CoAP supports this method since it requires the CoRE | ||||
Observe mechanism.</doc> | ||||
<request> | ||||
<param name="observe" style="header" type="xsd:integer"> | ||||
<option value = 1/> | ||||
</param> | ||||
</request> | ||||
<response status="2.05"> | ||||
<representation mediaType="text/plain"/> | ||||
<representation mediaType="application/senml+exi"/> | ||||
<representation mediaType="application/senml+xml"/> | ||||
<representation mediaType="application/senml+json"/> | ||||
</response> | ||||
</method> | ||||
<method id="update" name="PUT"> | <method id="update" name="PUT"> | |||
<doc>Control the actuator or update a parameter with a new value | <doc>Control the actuator or update a parameter with a new value | |||
or command. Both HTTP and CoAP support this method.</doc> | or command. Both HTTP and CoAP support this method.</doc> | |||
<request> | <request> | |||
<representation mediaType="text/plain"/> | <representation mediaType="text/plain"/> | |||
<representation mediaType="application/senml+exi"/> | <representation mediaType="application/senml+exi"/> | |||
<representation mediaType="application/senml+xml"/> | <representation mediaType="application/senml+xml"/> | |||
<representation mediaType="application/senml+json"/> | <representation mediaType="application/senml+json"/> | |||
</request> | </request> | |||
<response status="200"/> | <response status="200"/> | |||
<response status="2.04"/> | <response status="2.04"/> | |||
</method> | </method> | |||
<method id="getattr" name="GET"> | ||||
<doc>Retrieve the observe attributes associated with a resource. | ||||
Both HTTP and CoAP support this method.</doc> | ||||
<request> | ||||
<doc>This request MUST contain an Accept option with | ||||
application/link-format when the resource supports | ||||
other GET methods.</doc> | ||||
<representation mediaType="application/link-format"/> | ||||
</request> | ||||
<response status="200"> | ||||
<representation mediaType="application/link-format"/> | ||||
</response> | ||||
<response status="2.05"> | ||||
<representation mediaType="application/link-format"/> | ||||
</response> | ||||
</method> | ||||
<method id="setattr" name="PUT"> | ||||
<doc>Set the values of some or all of the observe attributes | ||||
associated with a resource. | ||||
Both HTTP and CoAP support this method.</doc> | ||||
<request> | ||||
<param name="pmin" style="query" type="xsd:integer"/> | ||||
<param name="pmax" style="query" type="xsd:integer"/> | ||||
<param name="lt" style="query" type="xsd:decimal"/> | ||||
<param name="gt" style="query" type="xsd:decimal"/> | ||||
<param name="st" style="query" type="xsd:decimal"/> | ||||
</request> | ||||
<response status="200"> | ||||
</response> | ||||
<response status="2.04"> | ||||
</response> | ||||
</method> | ||||
<method id="toggle" name="POST"> | <method id="toggle" name="POST"> | |||
<doc>Toggle the values of actuator resources. Both HTTP and CoAP | <doc>Toggle the values of actuator resources. Both HTTP and CoAP | |||
support this method.</doc> | support this method.</doc> | |||
<request> | <request> | |||
<doc>The toggle function is only applicable if the request | <doc>The toggle function is only applicable if the request | |||
is empty.</doc> | is empty.</doc> | |||
</request> | </request> | |||
<response status="200"/> | <response status="200"/> | |||
<response status="2.04"/> | <response status="2.04"/> | |||
</method> | </method> | |||
skipping to change at page 21, line 44 | skipping to change at page 23, line 34 | |||
Acknowledgement is given to colleagues from the SENSEI project who | Acknowledgement is given to colleagues from the SENSEI project who | |||
were critical in the initial development of the well-known REST | were critical in the initial development of the well-known REST | |||
interface concept, to members of the IPSO Alliance where further | interface concept, to members of the IPSO Alliance where further | |||
requirements for interface types have been discussed, and to Szymon | requirements for interface types have been discussed, and to Szymon | |||
Sasin, Cedric Chauvenet, Daniel Gavelle and Carsten Bormann who have | Sasin, Cedric Chauvenet, Daniel Gavelle and Carsten Bormann who have | |||
provided useful discussion and input to the concepts in this | provided useful discussion and input to the concepts in this | |||
document. | document. | |||
9. Changelog | 9. Changelog | |||
Changes from -02 to -03 | ||||
o Added lt and gt to binding format section. | ||||
o Added pmin and pmax observe parameters to Observation Attributes | ||||
o Changed the definition of lt and gt to limit crossing. | ||||
o Added definitions for getattr and setattr to WADL. | ||||
o Added getattr and setattr to observable interfaces. | ||||
o Removed query parameters from Observe definition. | ||||
o Added observe-cancel definition to WADL and to observable | ||||
interfaces. | ||||
Changes from -01 to -02 | Changes from -01 to -02 | |||
o Updated the date and version, fixed references. | o Updated the date and version, fixed references. | |||
o Removed pmin and pmax observe parameters [Ticket #336] | o Removed pmin and pmax observe parameters [Ticket #336] | |||
Changes from -00 to WG Document -01 | Changes from -00 to WG Document -01 | |||
o Improvements to the Function Set section. | o Improvements to the Function Set section. | |||
Changes from -05 to WG Document -00 | Changes from -05 to WG Document -00 | |||
skipping to change at page 23, line 14 | skipping to change at page 25, line 18 | |||
[RFC5988] Nottingham, M., "Web Linking", RFC 5988, October 2010. | [RFC5988] Nottingham, M., "Web Linking", RFC 5988, October 2010. | |||
[RFC6690] Shelby, Z., "Constrained RESTful Environments (CoRE) Link | [RFC6690] Shelby, Z., "Constrained RESTful Environments (CoRE) Link | |||
Format", RFC 6690, August 2012. | Format", RFC 6690, August 2012. | |||
10.2. Informative References | 10.2. Informative References | |||
[I-D.ietf-core-observe] | [I-D.ietf-core-observe] | |||
Hartke, K., "Observing Resources in CoAP", | Hartke, K., "Observing Resources in CoAP", | |||
draft-ietf-core-observe-15 (work in progress), | draft-ietf-core-observe-16 (work in progress), | |||
October 2014. | December 2014. | |||
[I-D.ietf-core-resource-directory] | [I-D.ietf-core-resource-directory] | |||
Shelby, Z., Bormann, C., and S. Krco, "CoRE Resource | Shelby, Z., Koster, M., Bormann, C., and P. Stok, "CoRE | |||
Directory", draft-ietf-core-resource-directory-01 (work in | Resource Directory", draft-ietf-core-resource-directory-03 | |||
progress), December 2013. | (work in progress), June 2015. | |||
[RFC6763] Cheshire, S. and M. Krochmal, "DNS-Based Service | [RFC6763] Cheshire, S. and M. Krochmal, "DNS-Based Service | |||
Discovery", RFC 6763, February 2013. | Discovery", RFC 6763, February 2013. | |||
[RFC7252] Shelby, Z., Hartke, K., and C. Bormann, "The Constrained | [RFC7252] Shelby, Z., Hartke, K., and C. Bormann, "The Constrained | |||
Application Protocol (CoAP)", RFC 7252, June 2014. | Application Protocol (CoAP)", RFC 7252, June 2014. | |||
Appendix A. Profile example | Appendix A. Profile example | |||
The following is a short definition of simple profile. This | The following is a short definition of simple profile. This | |||
skipping to change at page 24, line 36 | skipping to change at page 27, line 4 | |||
Authors' Addresses | Authors' Addresses | |||
Zach Shelby | Zach Shelby | |||
ARM | ARM | |||
150 Rose Orchard | 150 Rose Orchard | |||
San Jose 95134 | San Jose 95134 | |||
FINLAND | FINLAND | |||
Phone: +1-408-203-9434 | Phone: +1-408-203-9434 | |||
Email: zach.shelby@arm.com | Email: zach.shelby@arm.com | |||
Matthieu Vial | Matthieu Vial | |||
Schneider-Electric | Schneider-Electric | |||
Grenoble, | Grenoble, | |||
FRANCE | FRANCE | |||
Phone: +33 (0)47657 6522 | Phone: +33 (0)47657 6522 | |||
Email: matthieu.vial@schneider-electric.com | Email: matthieu.vial@schneider-electric.com | |||
Michael Koster | ||||
ARM | ||||
150 Rose Orchard | ||||
San Jose 95134 | ||||
FINLAND | ||||
Phone: | ||||
Email: michael.koster@arm.com | ||||
End of changes. 32 change blocks. | ||||
51 lines changed or deleted | 174 lines changed or added | |||
This html diff was produced by rfcdiff 1.42. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ |