Project

General

Profile

Notification » History » Version 6

Junxiao Shi, 05/23/2014 11:54 PM

1 5 Junxiao Shi
# Notification Stream
2 1 Junxiao Shi
3 5 Junxiao Shi
**Notification Stream** is a mechanism of [[Management|NFD Management protocol]].
4
It is a way to get updates about events happening in the forwarder.
5
This mechanism is useful for monitoring forwarder state.
6 1 Junxiao Shi
7
## Naming
8
9
* A stream of notifications is published under a certain Name prefix.
10
* A notification is a Data packet under this Name prefix with a sequence number.
11 5 Junxiao Shi
  * The sequence number component is a NameComponent containing a nonNegativeInteger.
12 1 Junxiao Shi
  * The sequence numbers of notifications in the same stream should be consecutive and increasing.
13
  * Each notification is limited to one Data packet.
14
15
Example:
16
17 5 Junxiao Shi
    ndn:/localhost/nfd/faces/events/%00 // first notification
18
    ndn:/localhost/nfd/faces/events/%01 // second notification
19 1 Junxiao Shi
20
## Notification publisher
21
22
Notifications from NFD are Data packets generated and signed by NFD.
23
24
These Data packets enter forwarding system via the InternalFace, and are subject to regular forwarding pipelines.
25
They should be admitted into the ContentStore.
26
27
## Notification subscriber
28
29 5 Junxiao Shi
The subscriber should typically request the Name of notification stream (`ndn:/localhost/nfd/faces/events` in the example) with ChildSelector=rightmost and Exclude=Any..*last-received-seq*.
30
If the subscriber has no knowledge of *last-received-seq*, the Exclude selector should be omitted.
31 1 Junxiao Shi
32 5 Junxiao Shi
* If no new notification has been generated after *last-received-seq*, this Interest will stay in the PIT, and be satisfied when a new notification is generated.
33 6 Junxiao Shi
* If one or more new notifications have been generated after *last-received-seq*, the Interest will be satisfied from the ContentStore, and the latest notification is returned.  
34
  The subscriber can retrieve missing notifications between *last-received-seq* and the returned latest notification by expressing additional Interests without Selectors.