Server Smalltalk Guide

Using JDK 1.2

In JDK 1.1, stub classes are assigned a hash value based on characteristics of the remote class, such as its name and the interfaces that it implements. In JDK 1.2, every stub class is assigned a hash value of 2.

In JDK 1.2, each method is also assigned a hash value based on the signature of that method. Remote calls pass this hash value to identify the correct method to call. Because the stub protocol has changed, the stub generation has also changed.

The new RMIC stub generation program shipped with JDK 1.2 generates three different types of stubs:

JDK 1.1 compliant stubs
JDK 1.1 stubs do not contain the method hash values.

JDK 1.2 compliant stubs
JDK 1.2 stubs contain the method hash values. Also, JDK 1.2 has obsoleted some RMI API and the JDK 1.2 stubs do not reference the obsoleted RMI API.

Hybrid stubs that can support both versions
The hybrid stubs can act as either JDK 1.1 stubs or JDK 1.2 stubs. The hybrid stubs determine the correct stub protocol based on which version of Java the local VM is running.

In order to use JDK 1.2, you must change the stub protocol version. To use JDK 1.2 with RMI, you must change the security. It is also recommended that you migrate your existing mappings in order to add the method hash value. Smalltalk can generate this method hash value dynamically. However, if it is generated dynamically, there are performance considerations.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]