码迷,mamicode.com
首页 > 其他好文 > 详细

CoAP Request and Response Rules

时间:2016-04-07 20:37:00      阅读:209      评论:0      收藏:0      [点我收藏+]

标签:

   CoAP specification (at the time of this writing, draft-18) does not clearly set out rules that define what would be a response for a given CON or a NON request. Embedded within the specification are various rules that are outlined. While many rules are still open and not clearly defined, the table below is a guidance that we have started following. Please note, this should be treated only as a guidance and not as something that is clearly defined by the CoAP Specifications.

Client SendsMessage Successfully Parsed and Understood By ServerServer Has all Information to Process the Request and can Successfully ProcessServer Sends Message TypeServer Sends Message CodeRemarks
CON YES YES ACK One of success response codes Happy day scenario
CON YES NO ACK One of failed response codes URI path in request is wrong and 4.04 not found is sent in ACK
CON NO NO RST One of failed response codes e.g. Unknown message code
NON YES YES     No response sent back
NON YES YES NON One of success response codes Response sent back as NON message
NON YES NO RST One of failed response codes URI path in request is wrong and 4.04 not found is sent in RST
NON NO NO RST One of failed response codes e.g. Unknown message code
NON YES YES CON One of request codes e.g. Previous NON request was for a data that requires confirmation from the sender on whether it reached the client or not

CoAP Request and Response Rules

标签:

原文地址:http://www.cnblogs.com/tifnan2015/p/5364839.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!