Jan Newmarch's Guide to Jini Technologies
Jan Newmarch
Version 4.03
23 March 2006
http://jan.newmarch.name/java/jini/tutorial/Jini.xml
1. Contents
This version uses Jini 2.1.
For a version using Jini 2.0, see
http://jan.newmarch.name/java/jini/tutorial.2.08/Jini.html
For a version using Jini 1.1 or 1.2, see
http://jan.newmarch.name/java/jini/tutorial.2.08/Jini.html
For a version using Jini 1.0, see
http://jan.newmarch.name/java/jini/tutorial.1.03/Jini.html
.
This book is being revised to use Jini 2.1. So far many chapters have
been revised and checked (against Jini 2.1)
and there are several new chapters (Jeri,Config, Logging, ServiceStarter, Advanced Security).
In time, the remaining chapters
will be converted. The new Jeri stuff is covered and the new security.
As an aid to the reader, there are additional tags
New material is in a different colour
and changed material is also in a different colour
Chapter versions labelled "4.00" contain changes usually related to Jini 2.1.
1.1
Chapters
This material has been adapted/checked against Jini 2.1:
-
Overview
(Last modified: version 4.01)
- Jini
- Eight Fallacies of Distributed Computing
- Success Stories
- Jini in One Hour
- Components
- Service Registration
- Client Lookup
- Proxies
- Client Structure
- Server Structure
- Partitioning an Application
- Support Services
- The End of Protocols
- Summary
-
TroubleShooting Jini
(Last modified: version 4.01)
- The Chapter that Shouldn't Exist
- Java Packages
- Jini and Java Versions
- Jini Packages
- HTTP Server
- Network Configuration
- Could not obtain preferred value for...
- Lookup Service
- RMI Stubs
- Garbage Collection
- Debugging
- Logging
-
Ant
(Last modified: version 4.01)
- Introduction
- Toplevel build file
- Project files
-
Discovering a Lookup Service
(Last modified: version 4.01)
- Lookup Service
- Unicast discovery
- Broadcast discovery
- ServiceRegistrar
- Summary
-
Entry Objects
(Last modified: version 2.02)
- Entry class
- Restrictions on entries
- Convenience Classes
- Further Uses of Entries
- Summary
-
Service Registration
(Last modified: version 4.01)
- ServiceRegistrar
- ServiceItem
- Registration
- ServiceRegistration
- Entries
- Summary
-
Client Search
(Last modified: version 4.01)
- ServiceRegistrar
- ServiceMatches
- Matching
- Summary
-
Leasing
(Last modified: version 4.01)
- Leases
- Granting and handling leases
- Summary
-
Simple Example
(Last modified: version 4.01)
- Problem Description
- Service Specification
- Common Classes
- Client
- Service Proxy
- Uploading a Complete Service
- Summary
-
Jini Extensible Remote Invocation
(Last modified: version 3.04)
- Jeri
- Traditional RMI
- Exporter
- Jeri
- Exported interfaces
- Configuration
- JRMP Proxies
- Basic Jeri Exporter
- Garbage Collection
- Proxy Accessor
- More Information
-
Choices for Service Architecture
(Last modified: version 3.03)
- Proxy Choices
- RMI Proxy for FileClassifier
- Non-RMI Proxy for FileClassifier
- RMI and non-RMI Proxies for FileClassifier
- Using the Naming service
- Using Other Services
-
Discovery Management
(Last modified: version 3.00)
- Management Interfaces
- LookupLocatorDiscovery
- LookupDiscoveryManager
- Conclusion
-
Join Manager
(Last modified: version 3.03)
- Join Manager
- Summary
-
Basic Security
(Last modified: version 2.06)
- Quick Fix
- Why AllPermission is Bad
- Removing AllPermission
- Jini with Protection
- Service Requirements
- Client Requirements
- RMI Parameters
- ServiceRegistrar
- Transaction Manager and other Activatable Services
- Phoenix
- rmid1.3
- Being Paranoic
-
More Complex Examples
(Last modified: version 4.01)
- Where is the Code
- Running threads from discovery
- Inexact Service Matching
- Matching using Local Services
- Finding a Service Once Only
- Leased Changes to a Service
-
Remote Events
(Last modified: version 4.01)
- Event Models
- Remote Events
- Event Registration
- Listener List
- Listener Source
- File Classifier with Events
- Leasing Event Listeners
- Monitoring Changes in Services
- Summary
-
ServiceDiscoveryManager
(Last modified: version 4.02)
- Introduction
- ServiceItemFilter
- Finding a Service Immediately
- Using a Filter
- Building a Cache of Services
- Monitoring Changes to the Cache
- Summary
-
Example: Flashing Clocks
(Last modified: version 3.06)
- Introduction
- Timer
- TickerTimer
- ComputerTimer
- ClockFrame
- TickerTimer Driver
- ComputerTimer Driver
- ClockDevice
- Runtime Behaviour
-
Configuration
(Last modified: version 3.02)
- Localhost
- Configuration
- Configuration File
- Configuration File
- Specifying the configuration
- Service Id
- Specifying codebase
- Localhost
- A generic server
-
Logging
(Last modified: version 3.01)
- Logging
- Logging LookupDiscovery
-
ServiceStarter
(Last modified: version 4.02)
- ServiceDescriptor
- Starting a nonactivatable service
- Starting a nonactivatable server
- Reggie
- Conclusion
-
Advanced Security
(Last modified: version 3.05)
- Introduction
- Invocation constraints
- Method constraints
- Logging
- Protocols
- Proxy preparer
- File classifier server
- Integrity
- Proxy verification
- Confidentiality
- Mix 'n Match
- Identity Management
-
Transactions
(Last modified: version 4.02)
- Introduction
- Transactions
- TransactionManager
- TransactionParticipant
- Mahalo
- Example
- Summary
-
User Interfaces for Jini Services
(Last modified: version 4.02)
- User Interfaces as Entries
- User Interfaces from Factory Objects
- Current Factories
- Marshalling Factories
- UIDEscriptor
- File Classifier Example
- Support Classes
- Images
- ServiceType
- MindStorms
- Summary
-
Activation
(Last modified: version 3.04)
- Introduction
- Phoenix
- A Service using Activation
- LeaseRenewalService
- LookupDiscoveryService
- Summary
-
Introspection
(Last modified: version 3.05)
- Basic Service Lister
- Unknown services
- Introspection
- Unknown classes
-
Extended Example: Home Audio
(Last modified: version 3.06)
- Introduction
- Distributed audio
- Parameters for A/V
- Source/sink interfaces
- Content interfaces
- Transport interfaces
- Linkages
- An HTTP source
- An HTTP OggVorbis source
- An HTTP sink
- Content sinks
- Sink implementation
- Servers
- Clients
- A file sink
- A file sink with GUI
- Conclusion
-
Web Services and Jini
(Last modified: version 4.03)
- Introduction
- Simple Web Service
- Bridging between Jini Client and Web Service (1)
- Bridging between Jini Client and Web Service (2)
- Web Service Client to Jini Service
- Summary
This material still uses Jini 1.2
-
Lego MindStorms
(Last modified: version 2.02)
- Making Hardware into Jini Services
- MindStorms
- MindStorms as a Jini Service
- RCXPort
- RCX Programs
- Jini classes
- Getting it running
- Entry objects for a robot
- A client-side RCX class
- Higher level mechanisms: Not Quite C
- Summary
-
CORBA and Jini
(Last modified: version 0.12)
- CORBA
- CORBA to Java Mapping
- Jini Proxies
- Simple Example
- Room Booking Example
- Migrating a CORBA Client to Jini
- Jini Service as a CORBA Object
- Summary
-
Servlets
(Last modified: version 2.08)
- Dynamic Web pages
- Servlets
- Jakarta Tomcat Configuration
- Servlet as Jini client
- Lookup Service Monitor
- FileClassifierServlet
- Deploying the Servlet
-
Java Network Launching Protocol
(Last modified: version 2.08)
- JNLP
- JNLP file
- Jini and JNLP Comparison
- Combining Jini and JNLP
- Configuring the Browser
- Non-core Files
- Security
- Setting Lookup Service Locations
- Example
-
Architecture
(Last modified: version 2.02)
- Threads
1.2
Appendices
-
Properties used in Jini
2.
Files
The source to the programs is available as a zip file
programs.zip.
The compiled classes are available as a zip file
classes.zip.
The documentation files are also available as a zip file
docs.zip.
This includes HTML versions of the files.
I am using XML as document
format, using a mishmash of the DocBook DTD with extra tags
and HTML thrown in. A Perl program, xml_handler.pl
,
is a handler
called by my Apache Web server to deliver XML files as HTML.
Postscript versions of the documentation files are in
postscript.zip.
These are generated using html2ps, and I know this produces Postscript
that does not print on all printers - in particular, our Kyocera printers.
If you have problems printing these, let me know the solution only.
Please note that the copyright license allows you to make single printed copies for
your own use, but not multiple printed copies.
3.
Update Information
This tutorial will be updated on a regular basis, maybe several times
a week. If you want to receive an email announcement of each version
release, send email to
jan@newmarch.name with subject ``Jini tutorial update''
4.
Feedback
I would appreciate any feedback on this tutorial, to ensure that
it is correct and meets the needs of readers. The feedback that
I have already received has been very valuable. Please send
comments/corrections/requests, etc, to
jan@newmarch.name
5. Other Resources
-
The Jini FAQ at
http://www.artima.com/jini/faq.html
-
Jini Community Web Site
http://www.jini.org/
-
Noel Enete's ``Nuggets'' tutorial at
www.enete.com/download/#_nuggets_
-
Eran Davidov's
timeservice
example at
www.artima.com/jini/resources/timeservice.html
-
Roger Whitney's lecture notes on ``Java Distributed Computing'' at
http://www.eli.sdsu.edu/courses/spring99/cs696/notes/
-
Benot Marchal's articles for Digital Cat's Java Resource Center at
www.javacats.com/US/articles/Ben/Jini1.html
(and Jini2.html, Jini3.html, etc)
-
Jini Home page
http://www.sun.com/jini/index.html
-
RMI Home page
http://java.sun.com/products/jdk/rmi/index.html
-
Jini mailing list
jini-users@java.sun.com
-
Jini mailing list archives
http://archives.java.sun.com/archives/jini-users.html
-
RMI mailing list
rmi-users@java.sun.com
-
RMI mailing list archives
http://archives.java.sun.com/archives/rmi-users.html
-
Jini Interface Repository for standardised service interfaces (empty
at present)
http://www.artima.com/jini/interrepo/
6.
Changes
See the file Changes for the list of
version releases and changes made between versions.
7.
Copyright Information
This tutorial (and the pages it contains) are covered by the OpenContent
license. This basically gives you freedom to do what you want with the
document in a similar way to the GNU license for software. Any changes or
additions that you make to this set of pages as a Web document
must be made publically available, and may be folded
into later versions of this tutorial. Any such inclusions will of course
be credited with your copyright, under the
OpenContent license.
On the other hand, the programs that this tutorial
references are also available unbundled from the tutorial, and do not
have the restriction that source derived from them must be made publically
available. So you can derive your own source code from them, without having
to make it public. I'm not sure what suitable license will do this...
And, of course, there is no warranty...
8. Acknowledgements
The author is grateful for comments on this tutorial from
-
Brian Jeltema,
jeltema@richdist.east.sun.com
-
Roger Whitney,
whitney@cs.sdsu.edu
-
Robbert van den Beld,
rbe@mms-dresden.de
-
Chitrarasu Muthaiyan,
chitrarasu@cswl.com
-
Stuart Remphrey,
Stuart.Remphrey@Aus.Sun.COM
-
JJ Larrea,
jlarrea@redtop.com
-
John McClain,
John.McClain@East.Sun.COM
-
Bob Scheifler,
rws@east.sun.com
-
Michel,
michel@mailblocks.com
The work reported in this tutorial has been funded in part by the
Co-operative Research Centre Program through the
Department of Industry, Science and Tourism of
the Commonwealth Government of Australia.
9. Copyright
If you found this chapter of value, the full book
"Foundations of Jini 2 Programming"
is available from
APress or
Amazon .
This file is Copyright (©) 1999, 2000, 2001, 2003, 2004, 2005
by Jan Newmarch
(http://jan.newmarch.name)
jan@newmarch.name.
This work is licensed under a
Creative Commons License, the replacement for the earlier Open Content License.