You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: draft-ietf-core-coap-pubsub.md
+22-29
Original file line number
Diff line number
Diff line change
@@ -222,7 +222,7 @@ The CBOR map includes the following configuration parameters, whose CBOR abbrevi
222
222
223
223
* 'resource-type': A required field used to indicate the resource type of the topic-data resource for the topic. It encodes the resource type as a CBOR text string. The value should be "core.ps.conf".
224
224
225
-
* 'media-type': An optional field used to indicate the media type of the topic-data resource for the topic. It encodes the media type as a this information as the integer identifier of the CoAP content-format (e.g., value is "50" for "application/json").
225
+
* 'topic-media-type': An optional field used to indicate the media type of the topic-data resource for the topic. It encodes the media type as a this information as the integer identifier of the CoAP content-format (e.g., value is "50" for "application/json").
226
226
227
227
* 'topic-type': An optional field used to indicate the attribute or property of the topic-data resource for the topic. It encodes the attribute as a CBOR text string. Example attributes include "temperature".
228
228
@@ -232,17 +232,8 @@ The CBOR map includes the following configuration parameters, whose CBOR abbrevi
232
232
233
233
* 'observer-check': An optional field that controls the maximum number of seconds between two consecutive Observe notifications sent as Confirmable messages to each topic subscriber. Encoded as a CBOR unsigned integer greater than 0, it ensures subscribers who have lost interest and silently forgotten the observation do not remain indefinitely on the server's observer list. If another CoAP server hosts the topic-data resource, that server is responsible for applying the observer-check value. The default value for this field is 86400, as defined in {{!RFC7641}}, which corresponds to 24 hours.
234
234
235
-
<!--
236
-
David N Christian A:
237
-
history resource with a counter 0 .. 100
238
-
-->
239
-
240
235
* 'topic-history': An optional field used to indicate how many previous resource representations the broker shall store for a topic. Encoded as an unsigned CBOR integer, it defines a counter representing the number of historical resource states the broker should retain. This enables subscribers to retrieve past states of the topic data when necessary, useful in scenarios where historical context is required (e.g., for data analytics or auditing). If this field is not present, no historical data will be stored.
* 'initialize': An optional boolean field that, when set to `true`, allows the topic-data path to be pre-populated with an empty string or other initial value during the topic creation process. This behavior facilitates one-shot publication and topic creation, enabling CoAP clients to subscribe by default without encountering a `4.04 Not Found` error. If this field is not present, the broker behaves as usual, and the topic-data path is not initialized.
247
238
248
239
## Discovery
@@ -510,7 +501,7 @@ For example, below is a request on the topic "ps/h9392":
@@ -576,7 +567,7 @@ A client can update a topic's configuration by submitting the updated topic repr
576
567
577
568
On success, the topic configuration is overwritten and server returns a 2.04 (Changed) response and the current full resource representation. The broker may chose not to overwrite parameters that are not explicitly modified in the request.
578
569
579
-
Note that updating the "topic-data" path will automatically cancel all existing observations on it and thus will unsubscribe all subscribers. Updating the "topic-data" may happen also after it being deleted, as described on {delete-topic-data}, this will in turn create a new "topic-data" path for that topic configuration.
570
+
Note that updating the "topic-data" path will automatically cancel all existing observations on it and thus will unsubscribe all subscribers. Updating the "topic-data" may happen also after it being deleted, as described on {{delete-topic-data}}, this will in turn create a new "topic-data" path for that topic configuration.
580
571
581
572
Similarly, decreasing max-subscribers will also cause that some subscribers get unsubscribed. Unsubscribed endpoints SHOULD receive a final 4.04 (Not Found) response as per {{!RFC7641}} Section 3.2.
582
573
@@ -596,7 +587,7 @@ Example:
596
587
/ topic-name / 0: "living-room-sensor",
597
588
/ topic-data / 1: "ps/data/1bd0d6d",
598
589
/ resource-type / 2: "core.ps.conf",
599
-
/ media-type / 3: "application/senml-cbor",
590
+
/ topic-media-type / 3: "application/senml-cbor",
600
591
/ topic-type / 4: "temperature",
601
592
/ expiration-date / 5: "2023-04-28T23:59:59Z"
602
593
}
@@ -610,7 +601,7 @@ Example:
610
601
/ topic-name / 0: "living-room-sensor",
611
602
/ topic-data / 1: "ps/data/1bd0d6d",
612
603
/ resource-type / 2: "core.ps.conf",
613
-
/ media-type / 3: "application/senml-cbor",
604
+
/ topic-media-type / 3: "application/senml-cbor",
614
605
/ topic-type / 4: "temperature",
615
606
/ expiration-date / 5: "2023-04-28T23:59:59Z",
616
607
/ max-subscribers / 6: 100,
@@ -656,7 +647,7 @@ Contrary to PUT, iPATCH operations will explicitly update some parameters, leavi
656
647
/ topic-name / 0: "living-room-sensor",
657
648
/ topic-data / 1: "ps/data/1bd0d6d",
658
649
/ resource-type / 2: "core.ps.conf",
659
-
/ media-type / 3: "application/senml-cbor",
650
+
/ topic-media-type / 3: "application/senml-cbor",
660
651
/ topic-type / 4: "humidity",
661
652
/ expiration-date / 5: "2023-05-28T23:59:59Z",
662
653
/ max-subscribers / 6: 5
@@ -984,18 +975,20 @@ This document defines parameters used in the messages exchanged between a client
984
975
Note that the media type application/core-pubsub+cbor MUST be used when these parameters are transported in the respective message fields.
0 commit comments