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: content.mkd
+14-13Lines changed: 14 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -255,27 +255,28 @@ Expired subscriptions MUST NOT be used anymore as chances are high that doing so
255
255
256
256
# Push Notification
257
257
258
-
A WebDAV-Push server MUST notify registered subscriptions when the content of a subscribed collection changes, this is when a member is added, changed or removed.
258
+
A WebDAV-Push server MUST notify registered subscriptions of a subscribed collection:
259
259
260
-
This means that a notification is sent whenever the `{DAV:}sync-token` (as defined in {{RFC6578}}) or the historical `{http://calendarserver.org/ns/:}GetCTag` changes.
260
+
- on a _content update_ of the collection: this is when a member is changed or removed, (as explained in {{RFC6578}}), so that the `{DAV:}sync-token` changes;
261
+
- on a _property update_ of the colleciton: this is when
262
+
- certain properties of the collection (like `DAV:{display-name}`) itself change,
263
+
- or the property itself is removed, which changes its `{DAV:status}` to 4xx.
261
264
262
-
[^todo] Data vs. metadata, only about members or also the subscribed collection itself?
263
-
264
-
[^todo]CalDAV/CardDAV: subscribe home-set?
265
+
[^todo] Which properties?
265
266
266
267
267
268
## Push Message
268
269
269
-
The push message body consists of a `push-message` element, which contains a `{DAV:}propstat` element with
270
+
The push message body consists of a `push-message` element, which contains a `{DAV:}propstat` element with a `{DAV:}prop` element that MUST contain the `topic` of the affected collection so that the client can identify it without doubt.
271
+
272
+
In case of a _content update_ of the affected collection, the `{DAV:}prop` element MUST contain a `{DAV:}sync-token` element to allow a client to ignore the push message when it already knows the latest state.
270
273
271
-
* an optional `{DAV:}status` element to notify the client that the collection has changed its status, and
272
-
* a `{DAV:}prop` element that
274
+
To indicate a _property update_ of the affected collection, a `{DAV:}status` element is added to the `{DAV:}prop` element:
273
275
274
-
* MUST contain the `topic` of the affected collection so that the client can identify it without doubt,
275
-
* SHOULD contain a `{DAV:}sync-token` element (when available) to allow a client to ignore the push message when it already knows the latest state,
276
-
* MUST NOT contain elements with sensitive data (unless message encryption is used).
276
+
* status code 200 to indicate properties of the affected collection have changed,
277
+
* status code 404 to indicate that the collection has been removed.
277
278
278
-
When the `{DAV:}status` element is present, it indicates a change of the status of the collection itself (and not its members). In this case, clients SHOULD check and process the relevant properties of the collection. Status code 404 or 410 is used to indicate that the collection has been removed.
279
+
Clients can determine whether a push message notifies about a content and/or property update by checking the presence of `{DAV:}sync-token`.
279
280
280
281
When necessary or useful, a server MAY
281
282
@@ -316,7 +317,7 @@ A server MAY use some logic like remembering the last successful delivery plus s
316
317
[^todo] Specific implementation notes for CalDAV/CardDAV. Especially a recommendation of what clients shall subscribe to and why:
317
318
318
319
* homesets → content updates may trigger calendar list refresh
319
-
* calendars → content updates may trigger sync, property updates may trigger calendar meta-data refresh
320
+
* calendars / address books → content updates may trigger sync, property updates may trigger calendar meta-data refresh
320
321
* principals → keep displayed user data up-to-date
0 commit comments