InfoQ

News

Jigsaw - the death knell of JSR277?

Posted by Alex Blewitt on Dec 03, 2008

Community
Java
Topics
Tags
Open JDK ,
JSR 277 ,
JSR 294 ,
OSGi ,
JSR 291

Following up from an earlier post about modularising the JDK (which InfoQ covered earlier), Mark Reinhold posted the announcement of Project Jigsaw as part of the OpenJDK. From the announcement:

In order to modularize JDK 7 in the next year or so, and in order better to inform the work of JSR 294, Sun will shortly propose to create Project Jigsaw within the OpenJDK Community.

This effort will, of necessity, create a simple, low-level module system whose design will be focused narrowly upon the goal of modularizing the JDK. This module system will be available for developers to use in their own code, and will be fully supported by Sun, but it will not be an official part of the Java SE 7 Platform Specification and might not be supported by other SE 7 implementations.

If and when a future version of the Java SE Platform includes a specific module system then Sun will provide a means to migrate Jigsaw modules up to that standard. In the meantime we’ll actively seek ways in which to interoperate with other module systems, and in particular with OSGi.

The stated goal - to modularise the JDK - should be achievable, especially since Apache Harmony has already demonstrated that the JDK can be modularised (and using OSGi manifests). But the goal is more interesting for another reason; it's being done outside of the JCP

The lack of visible progress, and the behind-closed-doors implementation effort that was JSR 277 meant that it was very difficult for others to be involved or influence the development. Often, that lead the standard down the wrong path, focussing too much on implementation details and not enough of an interoperable standard. Not only that, but the standard was an after-the-fact write-up, which meant that by the time it came to fix problems (such as odd version numbers) it was already too late. According to the post, JSR277 is 'on hold' but in practice it's dead.

Splitting JSR294 (previously superpackages, now module) back out of JSR277 is also a great move; this will introduce language changes that will allow modularisation to happen independently of any particular modularisation process.

What is also encouraging from the post is the realisation that OSGi is already a de-facto standard that's used for modularisation, and that co-operation is a good thing. That doesn't necessarily mean it will be based on OSGi though; in fact, it's suggesting that OSGi come together with it rather than the other way around:

OSGi If JSR 277’s JAM module system is an unsuitable foundation for modularizing the JDK, what about the OSGi Framework? This module system is reasonably mature, stable, and robust. Its core has even already been implemented within a Java virtual machine, namely that of Apache Harmony. OSGi is not at all integrated with the Java language, however, having been built atop the Java SE Platform rather than from within it.

This last problem can be fixed. Sun plans now to work directly with the OSGi Alliance so that a future version of the OSGi Framework may fully leverage the features of JSR 294 and thereby achieve tighter integration with the language.

I'm sure that it will be possible for a future OSGi standard to use JSR 294's modules, although there are some changes suggested. Either way, next week's Modularity in Java talk at Devoxx 08 should be an interesting revelation of the future of Java.

No comments

Watch Thread Reply

Educational Content

Brian Marick on 4 Challenges and 5 Guiding Values of Agile Software Development

Brian Marick takes us through a quick tour of the most important values and challenges to adopting Agile successfully (they aren't the typical challenges and values we hear in the community).

Are You a Software Architect?

The line between development and architecture is tricky. Does it exist at all? Is an ivory tower actually needed? There's a balance in the middle, but how do you move from developer to architect?

Agile – A Way of Life and Pragmatic Use of Authority

The word 'authority' sometimes produces an allergic response in hard-line agilists. Freedom and authority – both are bad if misused and both are good if used in right spirit for a noble cause.

Getting Started with Grails, Second Edition

"Getting Started with Grails" brings you up to speed on this modern web framework. Companies as varied as LinkedIn, Wired, and Taco Bell are all using Grails. Are you ready to get started as well?

Using ITIL V3 as a Foundation for SOA Governance

Those familiar with only ITIL V2 often scoff at the thought that ITIL could serve as a governance framework for SOA. With ITIL V3, the focus of the framework shifted towards service-orientation.

Adrian Colyer on AspectJ, tc Server and dm Server

SpringSource CTO Adrian Colyer discusses AspectJ, SpringSource's dm Server and tc Server products, OSGi and Scrum.

Adam Wiggins on Heroku

Heroku's Adam Wiggins talks about Rails, Background Jobs, Add-Ons, Ruby, and how Heroku manages to work around Ruby's inefficiencies using Erlang and other languages.

SOA as an Architectural Pattern: Best Practices in Software Architecture

For Grady Booch the foundation of a good architecture is patterns, SOA being just one of many patterns. In this Second Life presentation, Booch attempts to bring more clarity on what architecture is.