http://java.sun.com/ http://java.sun.com/ http://www.sun.com/javaone
JavaOne - Experiencing Java technology through education, industry, and community
2006 Conference
Topics
Sessions
   General Sessions
Hands-on Labs
Schedule
Schedule Builder
Register
Pavilion
   Cosponsors
   Exhibitors
   Media
   Presentation Theater
Java University
Daily Activities
Event Connect
Alumni
   Alumni FAQ
Multimedia Sessions
Community
JavaOne Online
Forums
java.sun.com
java.net
java.com
sun.com/developers
Java Wear & Books
Home > Sun Technical General Session

Demos Dazzle at the Java Platform Roadmaps Session

by Ed Ort

If you've attended past JavaOne conferences, you know that one of the highlights is the Java Platform "Roadmaps" session, where Sun's top technical folks outline the key directions for the next releases of the Java platform. At last year's JavaOne conference, Sun Vice president and Fellow Graham Hamilton highlighted some of the cool things planned for the next release of the Java platform for the desktop -- Java Platform, Standard Edition (Java SE) 6. Sun Distinguished Engineer Bill Shannon did the same for the next release of the Java platform for the enterprise -- Java Platform, Enterprise Edition (Java EE) 5. A year has passed and the future is now. Shannon noted happily, and to much applause from the crowd, that "Java EE 5 is done. The Java EE 5 specification was approved by the Java Community Process (JCP) two weeks ago and last week we released the Java EE 5 SDK." Java SE 6 is in the homestretch -- it's scheduled for final release in October.

With the availability of Java EE 5 and the near availability of Java SE 6, this session gave Hamilton and Shannon an opportunity to reiterate the themes that they highlighted in last year's session. But more than that, it gave them a chance to show off some of the new platform features by lacing their talk with some impressive demonstrations of Java SE 6 and Java EE 5 in action. Hamilton also shared a peek at some of the neat things planned for Java SE 7 (code named "Dolphin") and Shannon discussed possible future directions for Java EE.

Impressive Demos

Four snazzy demos highlighted the session:

  • Native Look and Feel on Windows.

    A lot of work has gone into enhancing desktop support in Java SE 6. One area of particular emphasis is the native look and feel of Swing applications in Windows. This effort has been a resounding success. In this demo, Chet Haase, an architect in the Java Client Group at Sun, launched an appointments desktop application that displayed a Swing-based GUI on Windows. You would be hard pressed to see any difference between the Swing GUI and the native Windows user interfaces and widgets on the screen. Haase then quickly switched to a Beta version of Vista (the next major version of the Windows operating system), and the look and feel of the Swing GUI changed immediately to a Vista look and feel. The application was also interesting because it demonstrated the rich client support for web services. The application accessed a Google calendaring web service. Haase then completed the demo by iconifying the application to the Windows system tray and then launching a native browser from the system tray. Support for iconifying to the system tray and the ability to launch native tools are two new desktop integration features.

  • Web Services With Java EE

    Ease of development is a major theme of both Java SE 6 and Java EE 5. One place where developers will find things markedly easier is web services. It's much simpler to develop and consume a web service in Java EE 5 than before. To demonstrate that, Ludo Champenois, a senior staff engineer at Sun and the chief architect for Java EE developer support in NetBeans, showed how quick and easy it is to build, deploy, and test a web service. Champenois used the newly-released NetBeans 5.5 Beta for the demonstration. After building and deploying the web service, Champenois easily built a client for the web service, deployed it and tested it. Then he quickly turned the web service into a transactional web service implemented as an Enterprise JavaBeans (EJB) 3.0 stateless session bean. (EJB 3.0, a part of Java EE 5, is yet another area where developers will see dramatic simplification in what they need to code.) Champenios then compiled, deployed, and tested the web service in just a few quick steps. Finally, he demonstrated the new Java Persistence API by adding database interaction to the transactional web service. In a few clicks, Champenois created an entity (what used to be called an entity bean) that represents the persistent database data and tied it to the web services application. As a backdrop to the demo, Shannon showed the highly streamlined source code for the web service, the client, and the entity. Annotations do a lot of the streamlining, and eliminate the need for deployment descriptors.

  • Visual Basic for Java

    One of the future goals of Java SE is giving Visual Basic developers easy access to the Java platform. There is an ongoing effort called Project Semplice to make this happen. Tor Norbye, a senior staff engineer at Sun Microsystems, demonstrated some of this vision using the Sun Java Studio Creator tool. Norbye is one of the technical leads on Java Studio Creator, and wrote Creator's visual webform editor. In this demo, Norbye created a simple web application that converts temperature in Farenheit to celsius. He showed off Creator's nifty visual development capabilities by doing a drag and drop to create the user interface for the application. Then he showed the source code and pointed out that it's not Java code, but rather Basic code (which in this case is much simpler to use to express the logic of the program). He also pointed out an interesting interplay between the Java Platform and Basic. "Celsius and Farenheit represent standard JavaServer Faces (JSF) technology components. Also the event handler for the application is being called from a Java web framework (JSF). So we actually have Java calling into Visual Basic, calling back into Java." Then came some VB-to-Java technology magic: he compiled the VB application source code, and voila, it generated Java classes. Norbye then ran the application and it correctly converted a Farenheit temperature that he entered into celsius.

    Hamilton noted that the objective of the project is not to enable users to run existing VB applications in Java. He explained that "existing Visual Basic applications are full of calls on Windows APIs. We're not trying to clone the Windows platform." Instead the idea is to leverage specific VB language skills to code new Java applications using Java APIs on the Java platform.

  • JavaScript in the Web Tier

    AJAX, an efficient way for a web application to handle user interactions with a web page, is definitely one of the hottest topics in the Java community. AJAX is supported in the Java SE and Java EE platforms, and that support will grow. On the Java EE side, that growth will add JavaScript to the web tier, complementing client-side JavaScript support. An effort called Project Phobos is working on providing that server-side scripting support. Developers will be able to embed JavaScript in JavaServer Pages (JSP) technology pages. The web tier will also support JavaScript servlets, which can be invoked on incoming POSTs and GETs. To demonstrate these capabilities, Sun senior staff engineer Roberto Chinnici ran a web application that did an interesting mashup of a user-contributed news site known as reddit and the social bookmarking site named del.icio.us. The application takes an RSS feed off of reddit and adds links to a del.icio.us bookmarked list. Chinnici showed some of the whizzy effects that AJAX enables for web pages and some other interesting capabilities such as attaching notes to added items and providing tool tips. He also showed that the server-side implementation uses JavaScript, that JavaScript is used in JSP pages, and that free-standing JavaScript servlets process incoming requests.

    In his discussion of this support, Shannon said that he envisions developers working in two AJAX-related styles: using high-level JavaServer Faces (JSF) components that are AJAX-enabled (where JavaScript is used behind the scenes), and doing "raw AJAX", where developers hand write AJAX code (though increasingly using toolkits such as Dojo). The Java web tier will support both styles of working with AJAX.

Openness: A Great Success

Beyond these enticing demos, one of the things that pervaded Hamilton's and Shannon's talks is the major impact that the Java community has made on Java SE 6 and Java EE 5. An important take-away from the session is that openness has been a great success and that the Java community should expect even more openness in the development process for future Java SE and Java EE releases. Community involvement has been a driving theme in Java SE 6 and Java EE 5. At last year's Java One conference, Hamilton and Shannon highlighted Project Peabody and Project GlassFish, community-based efforts that were established for collaborating on future Java SE and Java EE releases, respectively. Those efforts have borne fruit. Hamilton noted that community involvement has been extremely successful. He said that community-based feedback to the weekly snapshot releases has been great. It's allowed the community to pick up on new features and fixes. And giving the community access to the source has enabled them to contribute fixes and features early and often. Hamilton said that "this is working out really well for us and very well for the community so expect even more openness with the Dolphin release.'

Shannon underscored the significant contributions made by the GlassFish community, a community that has grown to over 2200 members. The GlassFish community built an open source Java EE application server that is the reference implementation of Java EE 5. In addition, the bits in the GlassFish application server went into the Java EE SDK, and the recently-released Sun Java System Application Server Platform Edition (PE) 9. Shannon encouraged the audience to explore the GlassFish community and to download the latest builds (there have been almost 300,000 downloads of GlassFish to date).

Systemic Properties

Hamilton started off his talk by covering what he termed "systemic properties," enhancements that permeate the release. These include:

  • Compatibility, Stability, Quality

    At last year's JavaOne session, Hamilton said that the primary theme, what he called "theme number one" is the combination of compatibility, stability, and quality. That theme continues to be the single most important focus for the team. Hamilton said that this focus has led to many internal process improvements. Complementing that focus is a more open community-based development model. As mentioned earlier, through access to weekly snapshots, the Java community has played a key role in identifying and fixing bugs. The focus on quality has also led to some novel contests such as the regression challenge, where the community helped identify regressions. A regression is a bug in which a function works in a previous release of the Java platform, but doesn't work in the current release. Hamilton said that 72 regressions were uncovered this way. Another contest, called "crack the verifier", asked the community to help validate the new bytecode verifier that's part of a new security model.

  • Performance

    Hamilton noted that performance has improved significantly in every release of the J2SE platform and that trend continues in Java SE 6. Users should see performance improvements in many areas of the platform, and on both the client and the server. Hamilton backed this up with two graphs. One showed the reduction in time that a grey rectangle or flicker appears when a window is moved on the screen and exposes part of a Swing application (this is a result of the application having to repaint). The grey rectangle exposure time for J2SE 1.5 is 200 milliseconds. That has dropped to 33 milliseconds. A second graph compared the performance of the SpecJBB2000 business benchmark running in J2SE 1.3, J2SE 1.4.2, J2SE 1.5, and Java SE 6. The graph showed that Java SE 6 was faster running the benchmark by about 20% compared to J2SE 1.5, and more than 3 times faster than J2SE 1.3.1.

  • RAS: Monitoring and Management

    Hamilton said that monitoring and management were key values in the J2SE 5.0 ("Tiger") release, and that adds to that. Some of the significant additions are more JVM-level diagnostics, improved OutofMemory diagnostic handling, attach-on-demand support which allows developers to attach the JConsole tool to any application for monitoring (Hamilton said that JConsole was "one of the surprise stars of Tiger"), and an assortment of upgrades to the JConsole tool and Java Management Extension (JMX) technology.

New Features

Hamilton went on to cover some of the important new features:

  • Scripting. Adds a new framework, covered by JSR 223, that allows scripting languages to access information developed in the Java platform. Also included is a JavaScript technology engine that's based on the Mozilla browser Rhino implementation. Hamilton also mentioned a Scripting project on java.net designed to provide additional scripting engine implementations that developers can use in their Java applications.

  • Desktop Enhancements. In addition to the desktop enhancements covered shown in the native look and feel demonstration, there are enhancements for various graphical APIs, including JTable (better support for sorting), SwingWorker, and GroupLayout. Also boosts the performance of Java 2D pipelines (particularly in Swing).

  • Web Services. Includes support for Java API for XML-based Web Services (JAX-WS) 2.0 (JSR 224) and Java Architecture for XML Binding (JAXB) 2.0 (JSR 222). JAX-WS provides a standard way of developing and accessing web services (it's also simpler to use than its predecessor, JAX-RPC). JAX-WS defines the interoperation model for web services. JAXB defines the XML data binding model for web services. It provides an automatic mapping between Java objects and XML schema, saving developers from having to worry about mapping details. Hamilton also mentioned the Tango project, an effort that extends the basic web services interoperability provided by JAX-WS between Java and .NET environments. This effort is designed to deliver much richer protocol support in areas such as web services security and messaging. Hamilton said that this support should be available on top and on top of Java EE 55 in 2007.

Hamilton also stressed that even if you're not interested in these newer features, it makes sense to move to take advantage of its systemic features. "Even if you've got older applications that are written to 1.4 or 5.0 APIs, you may want to quickly move those applications to benefit from the improved performance, improved monitoring and management, and improved stability and reliability."

Java EE 5 -- It's All About Ease of Use

Shannon followed Hamilton with a segment that highlighted the many simplifications that have been made in Java EE 5. Shannon noted that Java EE 5 makes things easier for developers by drawing even further on its declarative programming style, by removing a number of ungainly requirements, and by offering more powerful frameworks that mean less work for developers. Annotations are a big part of this simplification. Shannon noted that "originally we used deployment descriptors to communicate declarative information to the container. In Java EE 5 we've added the ability to use Java language annotations to communicate this information." In many cases, annotations remove the need for deployment descriptors. Annotations can be used extensively in Java EE 5 to do things as varied as define web services, map Java classes to databases, and specify external dependencies. As extensively as annotations are used in Java EE 5, Shannon said that it's only a start. "We're scratching the surface of what's possible."

As mentioned earlier, web services simplifications were highlighted in Shannon's talk, with some impressive demonstrations and J2EE 1.4-versus-Java EE 5 comparisons. The web services support in Java EE 5 is centered around JAX-WS 2.0 and JAXB 2.0. Shannon noted that these technologies support the latest World Wide Web Consortium (W3C) standards for web services, such as SOAP 1.2, and the latest Web Services Interoperability Organization (WS-I) standards, such as the WS-I Basic Profile 1.1. He also said that Java EE 5 implementations are starting to support WS* specifications such as WS-Security, and will support emerging WS* specifications over time.

Another area of simplification in Java EE 5 is EJB 3.0 technology. Because EJB 3.0 supports a Plain Old Java Object ("POJO") approach, annotations, and dependency injection (where the container provides the resources that an application needs rather than the application having to find the resources), what developers must code to use EJB technology is dramatically reduced. Shannon said that because of these simplifications, "you don't need to understand all of the EJB APIs and EJB interfaces in order to write applications that take advantage of the power of the EJB container."

The Java EE 5 platform also includes a new persistence API that defines a single model for implementing persistence in Java EE as well as in Java SE. It's much simpler to use than the previous EJB container-managed persistence model. Shannon said that feedback on the new persistence API has been overwhelmingly positive.

Ease of Use Through JavaServer Faces 1.2 Technology

Another ease-of-use "biggie" in Java EE 5 is JavaServer Faces (JSF) 1.2 technology, which gives developers a standard framework for building web applications in Java EE. Developers can use pre-packaged JSF components in building their applications, significantly reducing new code development. Shannon said that there are currently over 200 JSF components available from than 20 vendors. JSF 1.2 includes some important capabilities, such as support for AJAX (Shannon mentioned that the Java Blueprints Catalog includes several AJAX-enabled components for JSF), and an easy-to use but powerful expression language that it shares with JSP technology.

Ease of Use in Application Packaging Too

An area of simplification in Java EE 5 that's not often cited is application packaging. In many cases, Java EE applications no longer require deployment descriptors, and in general, require fewer XML files. These simplifications can significantly reduce the number of files in an application. Shannon pointed out that Adventure Builder, a sample application, has gone from 67 classes in J2EE 1.4 to 43 classes in Java EE 5. And the RosterApp sample application has gone from 17 classes and 9 XML files in J2EE 1.4 to 7 classes and 1 XML file in Java EE 5.

Compatibility With J2EE 1.4

Shannon stressed that all the new Java EE 5 features and simplifications have not been added at the expense of compatibility, "so your investment in J2EE 1.4 is protected in Java EE 5."

The Future

Both Hamilton and Shannon talked a bit about directions for the future. Hamilton said that the expert group is considering some "thoughtful changes" to the Java language for the Dolphin release. This includes direct support for XML and support for "super packages." Direct support for XML allows for inline XML literals as well as intermixing Java expressions in XML. It also might include lightweight support for XPath expressions to simplify getting and setting chunks of XML.

A super package is essentially a package of packages. It allows for large applications to be structured as a set of packages within one super package. This feature would also allow the packages to share state without exposing that state externally.

Some other enhancements for Dolphin include desktop improvements, such as more Java 2D desktop acceleration and Swing support for bean binding; better packaging as specified by the Java Module System specification (JSR 277); support for the lightweight BeanShell scripting language (JSR 274); better JVM performance; and the addition of new JVM bytecodes for non-Java languages (JSR 292). Hamilton said that the new bytecodes would allow for better support of dynamic languages such as Groovy and Python. And that's not all of it. Hamilton said that "there are well over 100 serious major features that are being considered."

Shannon was more general than Hamilton when covering future directions for Java EE. He said that its still too early to say anything definitive. A lot of the future direction depends on feedback from the community. He urged the audience to give specific feedback on Java EE 5. "Where did we not make it quite easy enough yet? What can we do to make it even easier? What did we do right?"

Shannon also said that there are various possible directions for growth: "we can grow upwards, downwards, and sideways." What Shannon meant by grow upwards is to expand Java EE into areas such as composite applications or adding portlet support to Java EE applications. By grow downwards, he meant adding things that enable lower-end applications to work with Java EE. This might include more support for scripting, support for web hosting and application hosting environments, and support for web-based distributed authoring and versioning (webDAV), as well as more support for tools. By grow sideways, he meant enhancing Java EE in the space in which it already exists. This might include a refinement of current support such as polishing current APIs, enhancing the current support for AJAX and web frameworks, and adding more support for WS* specifications. Shannon ended by stressing the importance of feedback from the community. "We need your feedback to guide us in determining which of these are most important to work on first."

Help Get the Word Out

Hamilton concluded the session by exhorting the crowd to get the word out about Java EE 5. "Java EE 5 is here now -- it's a no brainer for new projects. Arrives in October with many systemic upgrades and great new features." Judging by the buzz created in this session, no exhortation was needed -- developers will have little trouble spreading the word about the terrific things in the these platform releases.

 Back to top


Rate and Review
Tell us what you think of the content of this page.
Excellent   Good   Fair   Poor  
Comments:
If you would like a reply to your comment, please submit your email address:
Note: We may not respond to all submitted comments.