Provides utilities to bootstrap and initialize the Rio operational environment. Rio uses the Jini™ Technology Configuration approach to define the platform and components to create and initialize. This package document persents the following information:

- Understanding the classpath
- Configuring Boot Attributes

Classpath
When Rio starts, the classpath is set the to the following: boot.jar (which has a Class-Path manifest entry to start.jar) and start.jar (which has a Class-Path manifest entry to jsk-platform.jar). The remaining jars are dynamically loaded by the CommonClassLoader based on the platform configuration. The default platform configuration is loaded as a resource fro boot.jar (META-INF/platform.xml) declares the following:

JARs | Location Loaded From | Description
rio.jar | ${RIO_HOME}/lib | Rio core technology platform classes
platform-capabilities.jar | ${RIO_HOME}/lib | Platform capability classes
jsk-lib.jar | ${JINI_LIB} | The Jini 2.1 technology required platform classes. More information on Jini technology can be found here

Additional jars can be added to the platform by working with the Platform configuration. Platform configuration files are used as follows:

- Provides attributes for creating {@link org.jini.rio.qos.capability.PlatformCapability} classes and declaring what jars will be common across all service classloaders. If jars are common they are loaded by the CommonClassLoader, and are in the classpath of all child class loaders. By default Rio and Jini technology jars are commonacross all service classloaders.
- For platform capabilities that are not loaded by the common classloader, services that declare that dependency will have the capability loaded by the service's classloader.
- Provides a manifest of the platform jars that can be loaded.

Platform configuration files are loaded when Rio starts. The contents of the org.jini.rio.boot.platformDir directory will be scanned at startup time. Each .xml file will be parsed for <platform> declarations.
It is important to understand the class loader hierarchy. The approach is to enable a platform oriented framework conducive towards creating a layered product. The resulting capabilities allow the declaration of JARs that are added to a CommonClassLoader, making the classes accessible by all ClassLoader instances that delegate to the CommonClassLoader. In this fashion a platform can be declared, initialized and made available.
The ClassLoader hierarchy when starting Rio is as follows:

                      AppCL
                        |
                CommonClassLoader (http:// URLs of common JARs)
                        +
                        |
                        +
                +-------+-------+----...---+
                |               |          |
            Service-1CL   Service-2CL  Service-nCL

AppCL - Contains the main() class of the container. Main-Class in manifest points to com.sun.jini.start.ServiceStarter
Classpath: boot.jar, start.jar, jsk-platform.jar
Codebase: none
CommonClassLoader - Contains the common Rio and Jini technology classes (and other declared common platform JARs) to be made available to its children.
Classpath: Common JARs such as rio.jar
Codebase: Context dependent. The codebase returned is the codebase of the specific child CL that is the current context of the request.
Service-nCL - Contains the service specific implementation classes.
Classpath: serviceImpl.jar
Codebase: "serviceX-dl.jar rio-dl.jar jsk-lib-dl.jar"
Configuring Boot Attributes
The Rio boot environment supports the following configuration entries; where each configuration entry name is associated with the component name org.jini.rio.boot``

- platformDir

  Type: | String
  Default: | ${RIO_HOME}${/}config${/}platform
  Description: | The platformDir property is scanned at system startup time. For each file ending in .xml, the file is parsed for Platform Configuration declarations. The platform element contains capability declarations that document the qualitative capabilities a compute resource will advertise and make available for services to use.

- computeResource

  Type: | {@link org.jini.rio.qos.ComputeResource}
  Default: | new org.jini.rio.qos.ComputeResource(new String[] {"-"});
  Description: | Creates the ComputeResource component representing qualitative and quantitative capabilities of the compute resource the service is executing on. The org.jini.rio.qos.ComputeResource object has a single Constructor which takes as an argument a String[] which us used to construct a net.jini.config.Configuration object to use to provide attributes specific to the initialization of the org.jini.rio.qos.ComputeResource component

- createShutdownHook

  Type: | {@link java.lang.Boolean}
  Default: | true
  Description: | Creates a shutdown hook. This will result in the registration of a virtual-machine shutdown hook. The shutdown hook will provide an orderly shutdown of all ServiceBean instances the Cybernode has instantiated by calling the ServiceBean's destroy method

- verifyMulticast

  Type: | {@link java.lang.Boolean}
  Default: | false
  Description: | Determines if a Multicast socket can be created and a Request announcement can be sent. Note that it is still possible that multicast does not work outside the host

Default Platform Configuration
The default platform configuration is as follows:

<?xml version="1.0" encoding="UTF-8"?> <!-- Default platform configuration --> <platform> <!-- Rio jars to load into the common classloader. --> <capability name="Rio" class="org.jini.rio.qos.capability.software.RioSupport" common="yes"> <version>3.3</version> <classpath>${RIO_HOME}/lib/rio.jar ${RIO_HOME}/lib/platform-capabilities.jar</classpath> </capability> <!-- Jini jars to load into the common classloader. --> <capability name="Jini" common="yes"> <version>2.1</version> <manufacturer>Sun Microsystems</manufacturer> <classpath>${JINI_HOME}/lib/jsk-lib.jar</classpath> </capability> </platform>