Excelsior JET Now Supports Java SE 6 Update 10

We have just released Maintenance Pack 1 and the Java SE 6 Update 10 support add-on for Excelsior JET 6.4.

Among the improvements in Java SE 6u10, formerly known as “Update N” and “Consumer JRE”, are a new Swing look & feel called Nimbus and a fully hardware accelerated Windows graphics pipeline. As Excelsior JET includes the Java SE API implementation licensed from Sun, these improvements are now available to our customers.

We plan to have the Java SE 6 Update 11 support add-on available in January 2009.

Here is a screenshot of the new SwingSet3 demo with Nimbus L&F:

Excelsior JET 6.5 beta 3 is out

With release of version 6.5, Excelsior JET will become the first Java implementation that supports the OSGi runtime core at the JVM level. In particular, it will enable you to protect Eclipse RCP applications from reverse engineering and tampering.

In addition to the VM engineering, we also strive to make Excelsior JET easy to use for natively compiling RCP applications. Excelsior JET 6.5 beta 3 adds support for Eclipse RCP applications to the JET Control Panel, a GUI wizard for quick setup of Excelsior JET projects. As a side effect , this beta also includes a “bonus track”: consistency checks for RCP applications.

Here is the entire what’s new list for beta 3:

Eclipse RCP Support

  • JET Control Panel now provides GUI for compiling RCP applications
  • Numerous bug fixes and overall stability improvements
  • Over 98% of Eclipse Unit Tests have passed on the compiled Eclipse IDE

Scalability improvements

Compiling large applications takes less time and memory

Ease-of-use

The Welcome screen added to the JET Control Panel enables faster creation of the projects for specific types of applications

Two RCP applications

compiled with Excelsior JET 6.5 beta 3 are also available for download.

Consistency checks for Eclipse RCP applications

The powerful OSGi…

The Eclipse Runtime enables you to create a well-formed modular architecture for Java applications. Each OSGi bundle has a unique name space and explicitly declares the imported/exported packages, and the Runtime enforces these rules.

… strikes back

However, arranging application jars into a set of OSGi bundles may be difficult and error-prone, especially if the application jars are “strongly connected”, that is, have lots of cross-references. The typical issues that may arise are

  • redundant classes: two jars contain classes with the same package and class name and the jars are placed in the same OSGi bundle. In this case, the classes from one jar will be actually used at run time and the others become “deployment baggage”
  • absent classes: a piece of code references a class that cannot be found within the bundle and is not exported from the other bundles. Unless the “wanted” class appears at run time, ClassNotFoundException will be thrown when control reaches that code.

    If your test suite does not achieve 100% code coverage (including third-party jars), there is a chance that the problem will manifest itself on end user systems.

Excelsior JET to the rescue

To detect such inconsistencies before deployment, you may use Excelsior JET 6.5. The JET Control Panel can analyze your Eclipse RCP application and report the found issues. Under the covers, it takes the OSGi bundles of your application and statically applies the resolution procedure used by the Eclipse Runtime as if the application was started and the bundles were loaded.

The results

When implementing this feature, we were really curious if such warnings would be found in real Eclipse RCP applications, and the answer came soon. Here go two examples:

Eclipse Classic IDE 3.4 (Ganymede)
Redundant (duplicated) classes Referenced absent classes Unresolved super classes
7 138 18

A large commercial RCP application
Redundant (duplicated) classes Referenced absent classes Unresolved super classes
154 299 74

Note that “unresolved super class” is a severe warning. If the code of a method just references an absent class, say, invokes a method or uses a field of that class, ClassNotFoundException is thrown only when the referencing code is executed. You are lucky if that code is on a rarely executed branch and the enclosing method runs fine in most cases ( of course, this is an optimistic assumption :) . On the contrary, an absent super class prevents any usage of any classes derived from it because ClassNotFoundException will be thrown immediately when loading such a derived class.

Finally, if the application works flawlessly since it never uses the problematic classes, what is the point of deploying them to end user systems?

Try it yourself

To avoid surprises, check your Eclipse RCP application for consistency before deployment:

  1. Download and install Excelsior JET 6.5
  2. Start the JET Control Panel and click “Eclipse RCP Application” on the welcome screen
  3. Specify the directory to which your RCP application was exported either by the Product Export Wizard or by an automated build process
  4. Go to the page Classpath and press the “Check consistency” button in the bottom pane

As analysis completes, the detailed report will be displayed in a separate dialog.

You may then inspect the problematic bundles and classes and get the report in text form.

Take care!

Tags: ,

|