The Jini Lookup functions as a network bulletin board and clearinghouse for all services on the network. Unlike DNS which only contains IP addresses and their corresponding host names , Lookup stores pointers to all the services available on the network and also the actual code and/or pointers to the code for these services.

As an example of Lookup, let's examine how a printer would be added to a network using Jini technology. When the printer was first plugged into the network, it would load a printer driver, or an interface to the driver, into Lookup. When a client wants to use the printer, the driver and driver interface would get downloaded from the Lookup onto the client. In this way, clients do not need to be loaded in advance. Of course what makes all this work in a simplified fashion is the power of Java's write-once-run- anywhere model. The Java printer driver is guaranteed to work on any client with a Java Virtual Machine. Without Java technology, trying to store all the possible different printer drivers on the Lookup would be next to impossible .

The printer might also load other attributes into the Lookup. For instance, the printer might store attributes describing that it is a color printer and supports duplex printing, along with the print speed. Besides attributes, the printer could also load value added services into the Lookup. One example would be to store wizards that would run on the client and help with printer set up.

Because all networks may not contain a Lookup, a Peer Lookup capability is also defined. When a client desiring a service cannot find a Lookup on the network, it can register by sending out the same Discovery and Join packets a Lookup would use to request any service providers (this is what a Lookup does when it first is plugged into a network). Service providers would thus register with the client as though it were a Lookup. Peer Lookup obviously makes the most sense to implement when there is a very low density of Jini devices in a network. As more and more Jini capable devices are added to a network, it makes sense to implement a dedicated Lookup function.

Software Development. Building Reliable Systems
Software Development: Building Reliable Systems
ISBN: 0130812463
EAN: 2147483647
Year: 1998
Pages: 193
Authors: Marc Hamilton

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net