Alex Blewitt posted a great write up to InfoQ of Peter Kriens' recent presentation on the next release of OSGi, which is called R4.2.
This release started in September 2006 with the OSGi Enterprise Workshop. When I volunteered to co-chair the EEG in December I remember being told it would take about two years to get the release out. Pretty close I guess...
The presentation is kind of long (112 minutes), but well worth watching if you're interested in OSGi, or in hearing Peter's view of what's gone wrong with the Java Modularity initiative as currently defined in the JSR 294 community (of which he is a member) and how to fix it.
The new features in R4.2 are spread across the Core and Compendium parts of the , but the major changes in R4.2 are being driven by enterprise requirements, primarily represented in the Remote Services (formerly RFC 119) and Blueprint Container (formerly RFC 124) additions to the Compendium. The new service registry hooks in the core were similarly based on enterprise requirements (specifically from the Remote Services work).
But of course not done with the enterprise requirements. The EEG is meeting again next week, primarily to continue working on the Java EE component mappings Peter briefly references, which we hope to publish at the end of the year in an "Enterprise Profile" document, and start thinking about what's going to be in R5, scheduled for June 2010.
And we need to continue working on application metadata and the OSGi Bundle Repository definitions (despite the fact that Peter doesn't want to define an application ;-). The main reason for this is to provide a better foundation for the kind of development lifecycle tooling commonly used for enterprise application development.
We have made a good start, but there's lots more to do. Meanwhile the debate continues about whether or not it's a good idea to use OSGi for developing enterprise applications directly, or only indirectly through its incorporation in products.
R4.2 represents a significant step in this direction, but we still have a lot to do.
Showing posts with label EEG. Show all posts
Showing posts with label EEG. Show all posts
Wednesday, July 22, 2009
Thursday, June 11, 2009
OSGi Standard Questions
In my role as OSGi Enterprise Expert Group co-chair, I get a lot of questions about OSGi. I thought I'd post some of the more interesting ones here.
First, I was very surprised to hear someone from a large end-user organization say that they would be very interested in using OSGi, if only it were a standard.
The OSGi Specification is as much a standard as any specification developed in the Java Community Process, and more than some. I interpret this as what this person's Java EE vendor has been telling them, privately and in confidence of course, about OSGi.
The OSGi Specification started as JSR 8 back in 1999, and the current version (R4.2) is, as previous versions have been, an evolution of the original work, which was formally handed off from the JCP to the OSGi Alliance at the time. Certainly you could say the scope of modularizing Java (which is the essence of the OSGi Specification, after all) is potentially very broad, and you might question whether its entire potential scope has been standardized.
But you can also look at JSR 291 and see that the previous version of the OSGi Specification (R4.1) has already been officially adopted as a Java specification for a dynamic modularity system. The OSGi Alliance is, if anything, more open than the Java Community Process (and yes, I have participated in each, both at the technical level and the board level - in the case of JCP the former IONA rep elected to the EC reported to me).
Sun has never given up its control over the JCP or any specification it chooses to take the lead on. Anyone can join the OSGi Alliance and participate equally in the development of its specification. This is part of what is meaningful about a standard, that its future direction is open for anyone to participate. No vendor wants to invest a lot in implementing a standard that one of your competitors effectively controls the future of. (Thus the current controversy around the JCP and the whole debate about the future of the Java industry, whether it will continue to fragement etc.)
I suspect what this person really meant was "OSGi is not part of Java EE." That is true. But that is not necessarily a bad thing. I mean, having Java EE based on the OSGi Framework would be great. But having the future of OSGi under the control of the JCP, even to the extent of meeting the requirements of becoming part of Java EE, might not be very helpful to it (or to the future of modular programming in Java).
Before I get on to the next obvious question about Project Jigsaw (which you will notice studiously avoids mentioning OSGi), I want to point out that all Java EE vendors have already adopted OSGi, and built their app servers internally on it (well except JBoss, who has sort of tried to bolt OSGi onto their own microkernel, which seems weird). But they are, so far at least, advising against their customers obtaining the same benefits that motivated them to adopt the OSGi programming model internally - apparently including the argument that "OSGi is not a standard." This does not make sense, at least not for the consumers.
AFIAK Project Jigsaw is Sun's latest attempt to re-invent OSGi, or in any case block OSGi or create a substitute they can control. I understand the potential benefits of modularizing the language itself, and I know that the JSR 294 spec lead (Alex Buckley) spent some time liasing with the OSGi EEG (even attending a meeting and taking the abuse, pretty well anyway - I give him credit for trying to do the right thing), and that JSR 294 (which also studiously avoids mentioning OSGi) in theory is not strictly a documentation exercise for whatever they come up with in the OpenJDK project (which by the way is open in the same sense that the JCP is open - meaning it is under Sun's control), and that also in theory the modularity layer is "pluggable." All of this is sort of meant to indicate that OSGi compatibility or mapping is something the Project Jigsaw folks have in mind, if they are not actually working on it (which they are not as far as I can tell, and they also say nothing about this publicly - apparently only when someone brings up the topic of OSGi).
I was not at Java One this year, so I may have the wrong impression sitting remotely as I am, but my understanding is that the Project Jigsaw talks and demos did not mention OSGi. Nor did the descriptions of the plans for Java 7. So the short answer to the question of whether Project Jigsaw is a threat to Java modularity is that yes, it is.
One more thing to add - I have been following the Project Jigsaw public email list, and from what I could gather what was presented at Java One was more or less equivalent to what they could manage to get done by then. And while the demo looked interesting, and certainly seems to prove they got something working, it also is pretty scary when you think how far away that is from what's already available in the OSGi Framework.
First, I was very surprised to hear someone from a large end-user organization say that they would be very interested in using OSGi, if only it were a standard.
The OSGi Specification is as much a standard as any specification developed in the Java Community Process, and more than some. I interpret this as what this person's Java EE vendor has been telling them, privately and in confidence of course, about OSGi.
The OSGi Specification started as JSR 8 back in 1999, and the current version (R4.2) is, as previous versions have been, an evolution of the original work, which was formally handed off from the JCP to the OSGi Alliance at the time. Certainly you could say the scope of modularizing Java (which is the essence of the OSGi Specification, after all) is potentially very broad, and you might question whether its entire potential scope has been standardized.
But you can also look at JSR 291 and see that the previous version of the OSGi Specification (R4.1) has already been officially adopted as a Java specification for a dynamic modularity system. The OSGi Alliance is, if anything, more open than the Java Community Process (and yes, I have participated in each, both at the technical level and the board level - in the case of JCP the former IONA rep elected to the EC reported to me).
Sun has never given up its control over the JCP or any specification it chooses to take the lead on. Anyone can join the OSGi Alliance and participate equally in the development of its specification. This is part of what is meaningful about a standard, that its future direction is open for anyone to participate. No vendor wants to invest a lot in implementing a standard that one of your competitors effectively controls the future of. (Thus the current controversy around the JCP and the whole debate about the future of the Java industry, whether it will continue to fragement etc.)
I suspect what this person really meant was "OSGi is not part of Java EE." That is true. But that is not necessarily a bad thing. I mean, having Java EE based on the OSGi Framework would be great. But having the future of OSGi under the control of the JCP, even to the extent of meeting the requirements of becoming part of Java EE, might not be very helpful to it (or to the future of modular programming in Java).
Before I get on to the next obvious question about Project Jigsaw (which you will notice studiously avoids mentioning OSGi), I want to point out that all Java EE vendors have already adopted OSGi, and built their app servers internally on it (well except JBoss, who has sort of tried to bolt OSGi onto their own microkernel, which seems weird). But they are, so far at least, advising against their customers obtaining the same benefits that motivated them to adopt the OSGi programming model internally - apparently including the argument that "OSGi is not a standard." This does not make sense, at least not for the consumers.
AFIAK Project Jigsaw is Sun's latest attempt to re-invent OSGi, or in any case block OSGi or create a substitute they can control. I understand the potential benefits of modularizing the language itself, and I know that the JSR 294 spec lead (Alex Buckley) spent some time liasing with the OSGi EEG (even attending a meeting and taking the abuse, pretty well anyway - I give him credit for trying to do the right thing), and that JSR 294 (which also studiously avoids mentioning OSGi) in theory is not strictly a documentation exercise for whatever they come up with in the OpenJDK project (which by the way is open in the same sense that the JCP is open - meaning it is under Sun's control), and that also in theory the modularity layer is "pluggable." All of this is sort of meant to indicate that OSGi compatibility or mapping is something the Project Jigsaw folks have in mind, if they are not actually working on it (which they are not as far as I can tell, and they also say nothing about this publicly - apparently only when someone brings up the topic of OSGi).
I was not at Java One this year, so I may have the wrong impression sitting remotely as I am, but my understanding is that the Project Jigsaw talks and demos did not mention OSGi. Nor did the descriptions of the plans for Java 7. So the short answer to the question of whether Project Jigsaw is a threat to Java modularity is that yes, it is.
One more thing to add - I have been following the Project Jigsaw public email list, and from what I could gather what was presented at Java One was more or less equivalent to what they could manage to get done by then. And while the demo looked interesting, and certainly seems to prove they got something working, it also is pretty scary when you think how far away that is from what's already available in the OSGi Framework.
Labels:
EEG,
enterprise Java,
Java EE,
JCP,
modularity,
OSGi,
Project Jigsaw,
standards
Friday, March 13, 2009
OSGi BOF at EclipseCon
Update 3/16: Multiple OSGi BOFs at EclipseCon - Monday evening is the general OSGi BOF and Tuesday evening is the Enterprise OSGi BOF.
A week from Monday (wow time flies) the OSGi BOF will be held at EclipseCon. My EEG co-chair and I will be presenting an overview of the upcoming 4.2 OSGi specification release. The goal is to summarize the release and start a discussion. BJ and Peter are also going to be there, as are several other members of the core platform and enterprise expert groups, so this should be a good opportunity to engage the folks working to finish things up.
As this last sentence implies, the release is not yet completed, although it is being released in stages, and the core is about done. The compendium will follow, and later this year a collection of Java EE component mappings. So there is still an opportunity for feedback and input.
This week we also prepared another early release draft (third one) for approval by the OSGi Board, and with any luck this will be available early next week. It includes further updates to the RFCs (i.e. design docs) from which the specification updates are derived, some RFCs for Java EE mappings that haven't been previously published, and early drafts of the updated core and compendium.
We also just completed three days of (intense!) EG meetings, and therefore will have some recent updates to share.
Hope to see you at the 'Con! If not, please take a look at the early drafts and submit feedback.
A week from Monday (wow time flies) the OSGi BOF will be held at EclipseCon. My EEG co-chair and I will be presenting an overview of the upcoming 4.2 OSGi specification release. The goal is to summarize the release and start a discussion. BJ and Peter are also going to be there, as are several other members of the core platform and enterprise expert groups, so this should be a good opportunity to engage the folks working to finish things up.
As this last sentence implies, the release is not yet completed, although it is being released in stages, and the core is about done. The compendium will follow, and later this year a collection of Java EE component mappings. So there is still an opportunity for feedback and input.
This week we also prepared another early release draft (third one) for approval by the OSGi Board, and with any luck this will be available early next week. It includes further updates to the RFCs (i.e. design docs) from which the specification updates are derived, some RFCs for Java EE mappings that haven't been previously published, and early drafts of the updated core and compendium.
We also just completed three days of (intense!) EG meetings, and therefore will have some recent updates to share.
Hope to see you at the 'Con! If not, please take a look at the early drafts and submit feedback.
Labels:
Eclipse Con,
EEG,
Java EE,
OSGi,
OSGi Dev Con
Sunday, January 18, 2009
Making the OSGi Sausage (Nitrate Free)
This photo shows us hard at work (!) reviewing one of the many documents in process for the upcoming 4.2 release of the OSGi specifications.
The highlights of the meeting included Alex Buckley joining to discuss JSR 294, which has been recently reactivated. Unfortunately, he faced a difficult task in explaining to this group why JSR 294 had not based their work on the OSGi specificiations. Alex offered two answers: the first was about the benefits of aligning design time and runtime modularity, and the second was about the preference to include metadata about modularity directly in the language rather than in an external source.
We could only allocate about 90 minutes or so to this discussion, since we had a lot of other items to cover, so we were really only able to start the discussion. Alex was invited in the spirit of cooperation, and what I expect out if it is a definition of how the OSGi framework and JSR 294 can leverage each other. However, we will need more time to get to the bottom of this. IBM and Oracle are on the JSR 294 expert group, and with Alex's participation in the OSGi EGs, there should be good opportunities to continue the discussion in both forums.
On the basic work of the OSGi EGs, the theme is now getting things ready for the release. Several of the design documents have been voted on, meaning Peter Kriens can start updating the specifications to include them. As you may know if you have read the current OSGi Specifications, they are divided between the core specification and the compendium specification. The work of CPEG is basically aimed at updating the core, and the work of EEG basically aimed at updating the compendium. It's never exactly that simple, of course, but that's the main idea.
As usual, I'm going to focus my report on the EEG portion of the meeting. The major docs to pass EEG vote were distributed OSGi and the Spring-inspired blueprint component model. The JMX and JTA mappings also passed, but at least for JTA there's a relationship with JDBC and JPA as yet to be completed since the JDBC and JPA design docs are still in progress.
Another highlight of the EEG meeting was the discussion focused on evaluating what our work adds up to for enterprise developers. What kinds of applications can they create? What is the enterprise release good for, and what is it not good for? What are the gaps in our work, especially those that can be filled quickly (i.e. for this release).
As you may recall, if you have been following the EEG work, we are focusing now on which parts of Java EE make most sense to map to the OSGi framework. It seems that with Web apps, JTA, JDBC, JNDI, JPA, and JMX (although this is more precisely Java SE), distributed OSGi and Spring/Blueprint, we are in pretty good shape for meeting the requirements of most enterprise applications we could bring to mind. One important gap is JAAS, and so we will begin working to add that, too.
A large part of the discussion focused on issues that enterprise developers encounter when starting to incorporate OSGi bundles/services into their applications. First of all, what is an application? Unlike Java EE, where you can find the definition in an external file, the OSGi framework is dynamic, and the practical definition of an application therefore becomes whatever bundles are loaded at the time. In other words, the application is more or less self-describing.
But this isn't very helpful to someone who wants to figure out which bundles are in which "business applications" and how to build and maintain that application. I understand the resistance among OSGi folks to import a traditional static definition of such a thing, but on the other hand the world of OSGi software and existing Java code has to be integrated somehow. This is of course a lot of what SpringSource has been doing with its dm Server product - adapting existing Java code so it can be successfully used in OSGi projects.
Now let's take a step back for a moment, because the reasons to invest in OSGi based development need to be clear and of sufficient value to justify the effort. The two major benefits are modularity and dynamic deployment, which includes the ability to update an application without taking it down (there I go, using that word "application" again). The benefit of moduality is basically a development time benefit and can be achieved without a lot of recoding - although if one wants to support multiple deployment options (i.e. on an OSGi framework and also on Tomcat, an application server, or a proprietary container), then it gets more complicated.
But to obtain the ultimate benefit of 100% uptime, to deploy and update an application without having to cycle the container, you have to invest in making all modules into OSGi services. And here we start getting into the kinds of issues that Peter Rietzler and others have been blogging about lately. This inevitably brings up the question of "green field" applications, i.e. to what extent enterprise applications are likely to be coded completely from scratch (as opposed to having to use existing code).
Listening to the discussion, including Yan Pujante's summary of his experiences at LinkedIn, I became convinced that green field applications in the enterprise space are going to be highly unlikely. In other words, we are definitely going to have to deal with the compatibility issue - otherwise the adoption barrier would just be too high. I mean, you could argue (as I did) that the benefits of adopting OSGi services are so significant as to justify a rewrite, but the more I think about it, the less likely it seems to me that enterprises are in a position to do so.
Given this, it seems like we'll need a good sample application to illustrate how it's done, especially how it should be done, and how using an OSGi framework is different from using a Java EE container, or subset thereof. And it's probably even more important to describe how best to do it than it is to simply show the example.
Something that enterprise developers would also probably find helpful is the bundle repository, something along the lines of Oscar or the Spring dm Seerver's bundle repository. And BTW in general the SpringSource guys have done a lot of work to address the issues enterprise Java developers encounter when using OSGi.
An effort also was made to standardize the bundle repository capabilty, and the OSGi Alliance continues to discuss the possibility of hosting one (Peter Kriens and Frank Mittag are pushing for it) but work on the design doc was suspended a couple of years ago, more or less for lack of interest (this is how we do things at the OSGi Alliance, we rely on someone taking sufficient interest to put in some time and effort on something ;-).
Having a bundle repository available though would not only allow developers to search for needed bundles, but also provide support for provisioning bundles and automating several other deployment related capabilities. So we decided to try to pick this work back up and try to get something done for the next release.
One last comment relates to tooling. It isn't really in the EEG scope, but Peter Kriens said he would try to organize a joint meeting with some folks from the Eclipse Foundation, perhaps during EclipseCon (which is co-located with OSGi Dev Con) to talk about it. Bits and pieces of tooling for OSGi exists, but nothing comprehensive yet for enterprise developers. This would also help, of course.
See you next time.
Subscribe to:
Posts (Atom)
