rfc7641v2.txt   rfc7641.txt 
skipping to change at page 2, line 9 skipping to change at page 3, line 7
(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
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 4
1.1. Background . . . . . . . . . . . . . . . . . . . . . . . 2 1.1. Background . . . . . . . . . . . . . . . . . . . . . . . 4
1.2. Protocol Overview . . . . . . . . . . . . . . . . . . . . 3 1.2. Protocol Overview . . . . . . . . . . . . . . . . . . . . 4
1.3. Consistency Model . . . . . . . . . . . . . . . . . . . . 5 1.3. Consistency Model . . . . . . . . . . . . . . . . . . . . 6
1.4. Observable Resources . . . . . . . . . . . . . . . . . . 6 1.4. Observable Resources . . . . . . . . . . . . . . . . . . 7
1.5. Requirements Notation . . . . . . . . . . . . . . . . . . 7 1.5. Requirements Notation . . . . . . . . . . . . . . . . . . 8
2. The Observe Option . . . . . . . . . . . . . . . . . . . . . 7 2. The Observe Option . . . . . . . . . . . . . . . . . . . . . 8
3. Client-Side Requirements . . . . . . . . . . . . . . . . . . 8 3. Client-Side Requirements . . . . . . . . . . . . . . . . . . 9
3.1. Request . . . . . . . . . . . . . . . . . . . . . . . . . 8 3.1. Request . . . . . . . . . . . . . . . . . . . . . . . . . 9
3.2. Notifications . . . . . . . . . . . . . . . . . . . . . . 8 3.2. Notifications . . . . . . . . . . . . . . . . . . . . . . 10
3.3. Caching . . . . . . . . . . . . . . . . . . . . . . . . . 9 3.3. Caching . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.4. Reordering . . . . . . . . . . . . . . . . . . . . . . . 10 3.4. Reordering . . . . . . . . . . . . . . . . . . . . . . . 11
3.5. Transmission . . . . . . . . . . . . . . . . . . . . . . 11 3.5. Transmission . . . . . . . . . . . . . . . . . . . . . . 12
3.6. Cancellation . . . . . . . . . . . . . . . . . . . . . . 11 3.6. Cancellation . . . . . . . . . . . . . . . . . . . . . . 13
4. Server-Side Requirements . . . . . . . . . . . . . . . . . . 12 4. Server-Side Requirements . . . . . . . . . . . . . . . . . . 13
4.1. Request . . . . . . . . . . . . . . . . . . . . . . . . . 12 4.1. Request . . . . . . . . . . . . . . . . . . . . . . . . . 13
4.2. Notifications . . . . . . . . . . . . . . . . . . . . . . 13 4.2. Notifications . . . . . . . . . . . . . . . . . . . . . . 14
4.3. Caching . . . . . . . . . . . . . . . . . . . . . . . . . 13 4.3. Caching . . . . . . . . . . . . . . . . . . . . . . . . . 15
4.4. Reordering . . . . . . . . . . . . . . . . . . . . . . . 14 4.4. Reordering . . . . . . . . . . . . . . . . . . . . . . . 15
4.5. Transmission . . . . . . . . . . . . . . . . . . . . . . 15 4.5. Transmission . . . . . . . . . . . . . . . . . . . . . . 16
5. Intermediaries . . . . . . . . . . . . . . . . . . . . . . . 18 5. Intermediaries . . . . . . . . . . . . . . . . . . . . . . . 19
6. Web Linking . . . . . . . . . . . . . . . . . . . . . . . . . 19 6. Web Linking . . . . . . . . . . . . . . . . . . . . . . . . . 20
7. Security Considerations . . . . . . . . . . . . . . . . . . . 19 7. Security Considerations . . . . . . . . . . . . . . . . . . . 21
8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 20 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 22
9. References . . . . . . . . . . . . . . . . . . . . . . . . . 20 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 22
9.1. Normative References . . . . . . . . . . . . . . . . . . 20 9.1. Normative References . . . . . . . . . . . . . . . . . . 22
9.2. Informative References . . . . . . . . . . . . . . . . . 21 9.2. Informative References . . . . . . . . . . . . . . . . . 22
Appendix A. Examples . . . . . . . . . . . . . . . . . . . . . . 22 Appendix A. Examples . . . . . . . . . . . . . . . . . . . . . . 24
A.1. Client/Server Examples . . . . . . . . . . . . . . . . . 22 A.1. Client/Server Examples . . . . . . . . . . . . . . . . . 24
A.2. Proxy Examples . . . . . . . . . . . . . . . . . . . . . 25 A.2. Proxy Examples . . . . . . . . . . . . . . . . . . . . . 28
Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . 28 Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . 30
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 28 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 30
1. Introduction 1. Introduction
1.1. Background 1.1. Background
The Constrained Application Protocol (CoAP) [RFC7252] is intended to The Constrained Application Protocol (CoAP) [RFC7252] is intended to
provide RESTful services [REST] not unlike HTTP [RFC7230] while provide RESTful services [REST] not unlike HTTP [RFC7230] while
reducing the complexity of implementation as well as the size of reducing the complexity of implementation as well as the size of
packets exchanged in order to make these services useful in a highly packets exchanged in order to make these services useful in a highly
constrained network of themselves highly constrained nodes [RFC7228]. constrained network of themselves highly constrained nodes [RFC7228].
skipping to change at page 5, line 33 skipping to change at page 6, line 33
| | | |
| 2.05 Content | | 2.05 Content |
| Token: 0x4a | Notification upon | Token: 0x4a | Notification upon
| Observe: 60 | a state change | Observe: 60 | a state change
| Payload: 23.1 Cel | | Payload: 23.1 Cel |
|<-------------------+ |<-------------------+
| | | |
Figure 2: Observing a Resource in CoAP Figure 2: Observing a Resource in CoAP
Note: In this document, "Cel" stands for "degrees Celsius".
A client remains on the list of observers as long as the server can A client remains on the list of observers as long as the server can
determine the client's continued interest in the resource. The determine the client's continued interest in the resource. The
server may send a notification in a confirmable CoAP message to server may send a notification in a confirmable CoAP message to
request an acknowledgement from the client. When the client request an acknowledgement from the client. When the client
deregisters, rejects a notification, or the transmission of a deregisters, rejects a notification, or the transmission of a
notification times out after several transmission attempts, the notification times out after several transmission attempts, the
client is considered no longer interested in the resource and is client is considered no longer interested in the resource and is
removed by the server from the list of observers. removed by the server from the list of observers.
1.3. Consistency Model 1.3. Consistency Model
skipping to change at page 14, line 18 skipping to change at page 15, line 36
cannot tell if the observed state and the actual state are still in cannot tell if the observed state and the actual state are still in
sync. Thus, when the age of the latest notification becomes greater sync. Thus, when the age of the latest notification becomes greater
than its indicated Max-Age, the client no longer has a usable than its indicated Max-Age, the client no longer has a usable
representation of the resource state. The server MAY wish to prevent representation of the resource state. The server MAY wish to prevent
that by sending a new notification with the unchanged representation that by sending a new notification with the unchanged representation
and a new Max-Age just before the Max-Age indicated earlier expires. and a new Max-Age just before the Max-Age indicated earlier expires.
4.3.2. Validation 4.3.2. Validation
A client can include a set of entity tags in its request using the A client can include a set of entity tags in its request using the
ETag Option. When a observed resource changes its state and the ETag Option. When an observed resource changes its state and the
origin server is about to send a 2.05 (Content) notification, then origin server is about to send a 2.05 (Content) notification, then
whenever that notification has an entity tag in the set of entity whenever that notification has an entity tag in the set of entity
tags specified by the client, the server MAY send a 2.03 (Valid) tags specified by the client, the server MAY send a 2.03 (Valid)
response with an appropriate ETag Option instead. response with an appropriate ETag Option instead.
4.4. Reordering 4.4. Reordering
Because messages can get reordered, the client needs a way to Because messages can get reordered, the client needs a way to
determine if a notification arrived later than a newer notification. determine if a notification arrived later than a newer notification.
For this purpose, the server MUST set the value of the Observe Option For this purpose, the server MUST set the value of the Observe Option
skipping to change at page 20, line 37 skipping to change at page 22, line 21
| Number | Name | Reference | | Number | Name | Reference |
+--------+---------+-----------+ +--------+---------+-----------+
| 6 | Observe | RFC 7641 | | 6 | Observe | RFC 7641 |
+--------+---------+-----------+ +--------+---------+-----------+
9. References 9. References
9.1. Normative References 9.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/ Requirement Levels", BCP 14, RFC 2119,
RFC2119, March 1997, DOI 10.17487/RFC2119, March 1997,
<http://www.rfc-editor.org/info/rfc2119>. <http://www.rfc-editor.org/info/rfc2119>.
[RFC5988] Nottingham, M., "Web Linking", RFC 5988, DOI 10.17487/ [RFC5988] Nottingham, M., "Web Linking", RFC 5988,
RFC5988, October 2010, DOI 10.17487/RFC5988, October 2010,
<http://www.rfc-editor.org/info/rfc5988>. <http://www.rfc-editor.org/info/rfc5988>.
[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, DOI 10.17487/ Application Protocol (CoAP)", RFC 7252,
RFC7252, June 2014, DOI 10.17487/RFC7252, June 2014,
<http://www.rfc-editor.org/info/rfc7252>. <http://www.rfc-editor.org/info/rfc7252>.
9.2. Informative References 9.2. Informative References
[GOF] Gamma, E., Helm, R., Johnson, R., and J. Vlissides, [GOF] Gamma, E., Helm, R., Johnson, R., and J. Vlissides,
"Design Patterns: Elements of Reusable Object-Oriented "Design Patterns: Elements of Reusable Object-Oriented
Software", Addison-Wesley Professional Computing Series, Software", Addison-Wesley Professional Computing Series,
1994. 1994.
[REST] Fielding, R., "Architectural Styles and the Design of [REST] Fielding, R., "Architectural Styles and the Design of
Network-based Software Architectures", Ph.D. Dissertation, Network-based Software Architectures", Ph.D. Dissertation,
University of California, Irvine, 2000, University of California, Irvine, 2000,
<http://www.ics.uci.edu/~fielding/pubs/dissertation/ <http://www.ics.uci.edu/~fielding/pubs/dissertation/
fielding_dissertation.pdf>. fielding_dissertation.pdf>.
[RFC1982] Elz, R. and R. Bush, "Serial Number Arithmetic", RFC 1982, [RFC1982] Elz, R. and R. Bush, "Serial Number Arithmetic", RFC 1982,
DOI 10.17487/RFC1982, August 1996, DOI 10.17487/RFC1982, August 1996,
<http://www.rfc-editor.org/info/rfc1982>. <http://www.rfc-editor.org/info/rfc1982>.
[RFC5405] Eggert, L. and G. Fairhurst, "Unicast UDP Usage Guidelines [RFC5405] Eggert, L. and G. Fairhurst, "Unicast UDP Usage Guidelines
for Application Designers", BCP 145, RFC 5405, DOI for Application Designers", BCP 145, RFC 5405,
10.17487/RFC5405, November 2008, DOI 10.17487/RFC5405, November 2008,
<http://www.rfc-editor.org/info/rfc5405>. <http://www.rfc-editor.org/info/rfc5405>.
[RFC5989] Roach, A., "A SIP Event Package for Subscribing to Changes [RFC5989] Roach, A., "A SIP Event Package for Subscribing to Changes
to an HTTP Resource", RFC 5989, DOI 10.17487/RFC5989, to an HTTP Resource", RFC 5989, DOI 10.17487/RFC5989,
October 2010, <http://www.rfc-editor.org/info/rfc5989>. October 2010, <http://www.rfc-editor.org/info/rfc5989>.
[RFC6202] Loreto, S., Saint-Andre, P., Salsano, S., and G. Wilkins, [RFC6202] Loreto, S., Saint-Andre, P., Salsano, S., and G. Wilkins,
"Known Issues and Best Practices for the Use of Long "Known Issues and Best Practices for the Use of Long
Polling and Streaming in Bidirectional HTTP", RFC 6202, Polling and Streaming in Bidirectional HTTP", RFC 6202,
DOI 10.17487/RFC6202, April 2011, DOI 10.17487/RFC6202, April 2011,
<http://www.rfc-editor.org/info/rfc6202>. <http://www.rfc-editor.org/info/rfc6202>.
[RFC6690] Shelby, Z., "Constrained RESTful Environments (CoRE) Link [RFC6690] Shelby, Z., "Constrained RESTful Environments (CoRE) Link
Format", RFC 6690, DOI 10.17487/RFC6690, August 2012, Format", RFC 6690, DOI 10.17487/RFC6690, August 2012,
<http://www.rfc-editor.org/info/rfc6690>. <http://www.rfc-editor.org/info/rfc6690>.
[RFC7228] Bormann, C., Ersue, M., and A. Keranen, "Terminology for [RFC7228] Bormann, C., Ersue, M., and A. Keranen, "Terminology for
Constrained-Node Networks", RFC 7228, DOI 10.17487/ Constrained-Node Networks", RFC 7228,
RFC7228, May 2014, DOI 10.17487/RFC7228, May 2014,
<http://www.rfc-editor.org/info/rfc7228>. <http://www.rfc-editor.org/info/rfc7228>.
[RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer
Protocol (HTTP/1.1): Message Syntax and Routing", RFC Protocol (HTTP/1.1): Message Syntax and Routing", RFC
7230, DOI 10.17487/RFC7230, June 2014, 7230, DOI 10.17487/RFC7230, June 2014,
<http://www.rfc-editor.org/info/rfc7230>. <http://www.rfc-editor.org/info/rfc7230>.
Appendix A. Examples Appendix A. Examples
A.1. Client/Server Examples A.1. Client/Server Examples
 End of changes. 8 change blocks. 
43 lines changed or deleted 45 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/