WS-BaseNotification
Encyclopedia
WS-BaseNotification is a web services specification which defines the interface WS-Notification
WS-Notification
WS-Notification is a group of specifications related to the WS-Resource framework that allows event driven programming between web services.WS-Notification is based on the event notification pattern...

 clients (consumers) and servers (producers) should expose.

Subscription

The subscribe method (exposed through the NotificationProducer interface) allows consumers to register their interest in topics
WS-Topics
WS-Topics is a web services specification that works as part of the WS-Notification specification family, providing a method to define and address topics to which web service consumers can subscribe, as well as organising them into complex structures allowing hierarchies and synonyms .In topic...

; using the method, it is also possible to set a subscription expiry time and a custom boolean
Boolean logic
Boolean algebra is a logical calculus of truth values, developed by George Boole in the 1840s. It resembles the algebra of real numbers, but with the numeric operations of multiplication xy, addition x + y, and negation −x replaced by the respective logical operations of...

 filter. A subscription to a topic implies a subscription to all children of that topic in the topic space.

A useful feature of WS-BaseNotification is that the client calling subscribe can subscribe on behalf of the consumer - this is very useful in areas such as grid computing
Grid computing
Grid computing is a term referring to the combination of computer resources from multiple administrative domains to reach a common goal. The grid can be thought of as a distributed system with non-interactive workloads that involve a large number of files...

, where often subscriptions require specific privileges, but the service with that privilege wishes to defer processing to another service.

Subscription filters

An XPath
XPath
XPath is a language for selecting nodes from an XML document. In addition, XPath may be used to compute values from the content of an XML document...

 filter can be provided at subscribe-time that narrows down the notifications a consumer will receive. Before any notification is dispatched, the producer will run the XPath expression; if the expression does not match the notification being processed then that consumer will not receive a notification

Pausing/resuming subscriptions

The PauseSubscription and ResumeSubscription methods (exposed through the SubscriptionManager interface) allow consumers to temporarily suspend their subscriptions and allows the resumption of notifications.

Subscriptions can be resumed with one of the following policies regarding missed notifications:
  • Send notification on next new change - a similar effect to unsubscribing and then resubscribing.
  • Send the last notification that the consumer would have received had the subscription not been paused.
  • Send all the notifications that the consumer missed out on while the subscription was paused.

Unsubscription

As its name implies, the unsubscribe method allows a consumer to cancel an existing subscription. (Available in 1.3)

Notification

The consumer's notify method (exposed through the NotificationConsumer interface) is invoked every time a notification is available on a topic to which they have subscribed, and that notification has passed.

See also

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK