3.2.4.5.1 Version 1 Notification Ports

To create a version 1 notification port, the client SHOULD call ApiCreateNotify (section 3.1.4.1.56)  for protocol version 2, or section 3.1.4.2.56 for protocol version 3) to obtain an HNOTIFY_RPC context handle. Upon successful completion of ApiCreateNotify, the client SHOULD create a client-side queue associated with the notification port, as described in section 3.2.1.1, to hold event indications later received using the ApiGetNotify method (protocol version 2 or protocol version 3) as well as CLUSTER_CHANGE_CLUSTER_STATE, CLUSTER_CHANGE_CLUSTER_RECONNECT, and CLUSTER_CHANGE_HANDLE_CLOSE event indications. No event indications are queued by the server to the notification port until an event filter with an optional target cluster object has been registered with the port.

After the port is opened, the client MAY register an event filter to instruct the server to begin queuing the respective event indications on the port. The following methods are used to register the event filters:

  • ApiAddNotifyCluster (section 3.1.4.1.58 for protocol version 2, or section 3.1.4.2.58 for protocol version 3)

  • ApiAddNotifyNode (section 3.1.4.1.59 for protocol version 2, or section 3.1.4.2.59 for protocol version 3)

  • ApiAddNotifyGroup (section 3.1.4.1.60 for protocol version 2, or section 3.1.4.2.60 for protocol version 3)

  • ApiAddNotifyResource (section 3.1.4.1.61 for protocol version 2, or section 3.1.4.2.61 for protocol version 3)

  • ApiAddNotifyKey (section 3.1.4.1.62 for protocol version 2, or section 3.1.4.2.62 for protocol version 3)

  • ApiAddNotifyNetwork (section 3.1.4.1.90 for protocol version 2, or section 3.1.4.2.90 for protocol version 3)

  • ApiAddNotifyNetInterface (section 3.1.4.1.99 for protocol version 2, or section 3.1.4.2.99 for protocol version 3)

After the first event filter is registered, the client SHOULD call ApiGetNotify to begin receiving event indications that are queued to the port. The client MAY continue to register additional event filters as necessary.

When a client has finished performing operations with an HNOTIFY_RPC context handle, it SHOULD unblock any outstanding ApiGetNotify calls by calling ApiUnblockGetNotifyCall (section 3.1.4.1.107) for protocol version 2, or section 3.1.4.2.107 for protocol version 3<226> and then release the context handle by calling ApiCloseNotify (section 3.1.4.1.57 for protocol version 2, or 3.1.4.2.57 for protocol version 3).