Globus Toolkit 4: Programming Java Services

Chapter 13: Notifications

In this chapter we will introduce the concept of notification, a common design pattern that allows clients to be notified when interesting events happen in a server. In particular, we will focus on WS-Notifications, a family of specification that allow us to use this design pattern with Web Services. Then, we will see two examples of how we can use notifications in our services.

13.1 What Are Notifications?

Notifications are nothing new. It's a very popular software design pattern, although you might know it with a different name, such as Observer/Observable. Let's suppose that our software had several distinct parts (e.g. a GUI and the application logic, a client and a server, etc.) and that one of the parts of the software needs to be aware of the changes that happen in one of the other parts. For example, the GUI might need to know when a value is changed in a database, so that the new value is immediately displayed to the user. Taking this to the client/server world is easy: suppose a client needs to know when the server reaches a certain state, so the client can perform a certain action.

The most crude approach to keep the client informed is a polling approach (Figure13.1). The client periodically polls the server (asks if there are any changes). For example, let's suppose a client applications wants to know when the load of a server drops below 50%. The server is called the producer of events...

UNLIMITED FREE
ACCESS
TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: Bug Tracking Software
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.