![]() |
Jini Summary
|
|---|
|
Abstract: Jini is Sun's distributed processing infrastructure
for consumer devices. It has the special ability
to "recognize" devices that have just been plugged into the
network without prior knowledge of the device.
|
|
Jini is an approach to distributed processing that is known for its dynamic configuration. Sun says Jini provides the equivalent to a "dial tone" on a computer network. A device can plug into a Jini network and become imediately available to other devices on the network without manual configuration. Jini consists of class libraries and a few server
programs. It makes use of Java's version of remote
procedure call called remote method invocation or RMI. Jini
takes up 400K which includes the class libraries, the server
programs, and the virtual machine. Sun is pursuing a
strategic initiative to help OEM clients make their smart
devices "Jini compliant."
|
|
Jini's dynamic nature comes from the clever application of
mobile code. To explain, let me describe what happens when
a device is plugged into a Jini network.
|
![]() Figure 1: Lookup Service |
|
An active Jini network uses a server known as the Jini Lookup Service (figure 1). When a device is plugged into a Jini network, it uses the
Jini class libraries to "discover" the lookup service. If
the device has any services to contribute to the network, it
registers them with the lookup service (figure 2).
|
![]() Figure 2: Registration |
|
As part of registration, the device copies the class required to use its service to the lookup service. So the lookup service, not only has knowledge that a service
is available, it also has the executable class through which
the service is invoked. Figure 3 shows what a Jini network
would look like after two devices have registered.
|
![]() Figure 3: Service Devices |
|
A service bearing device might be a sharable DVD drive, a
VCR, a microwave, a television, or even an automated
sprinkler system. Any device that has a service to
contribute can offer its service over a Jini network.
|
|
Now figure 4 shows how a new device finds and makes use of
the existing Jini services.
|
![]() Figure 4: Lookup |
|
The new device uses the Jini class libraries to discover the lookup service, then asks for all of its services. As a part of the reply, the lookup service sends the user interface class for each service back to the new device. The user of the new device can select any of these
classes and interact with the GUI they present. When the
user interface class decides that the user has made a service
request, it contacts the service from which it came and invokes
the service, receives the reply, and renders it for the user.
|
|
The special part about Jini is that the executable that is needed to use a service is passed to the requester. Clients do not need advanced knowledge of the service because the service provides the class to use when accessing it. This is a clever use of mobile code. The serving devices do not need to be consumer devices. They could be server programs running in regular computers or coke machines publishing their current contents. One final note about terminology. A server program that
participates in a Jini network is known as a Jini service
rather than a Jini server. Jini is moving from the paradigm
of client/server to client/service. Every computing device
is given the option of providing service and requesting
service.
|
|
by Noel Enete . . . NDEnete@aol.com . . . www.enete.com |