主题:【IT新闻】Java 5.0(代号虎子)终于正式发布了 -- Highway
这里是记者采访Sun Java主要结构设计师Graham Hamilton的对话
Java 2 Platform, Standard Edition 5.0 (J2SE 5.0), the most extensive update of the Java platform since its inception in 1995, has arrived. The new release (code-named "Tiger") is designed for exceptional quality, improved ease of development, greater speed, enhanced performance, and extended monitoring and management capabilities.
To get up to speed on J2SE 5.0, we met with Graham Hamilton, Sun Fellow in the Java platform team at Sun Microsystems. Hamilton was the lead architect for J2SE releases 1.3, 1.4, and now, 5.0. His current projects include planning for post-Tiger JDK releases, an Ease-of-Development initiative across J2SE and Java 2 Platform, Enterprise Edition (J2EE), and work with Sun's tools group on new tools initiatives.
Gaining Familiarity with J2SE 5.0 Developers can download the JDK here: http://java.sun.com/j2se/1.5.0/download.jsp
I'm also happy to report that Tiger looks like our highest quality J2SE release ever. Quality had been job #1 throughout the release development and this has paid off. In his recent blog, Mark Reinhold, Chief Engineer for J2SE, talks about how well we are doing on our various quality metrics.
An Easier Time for Developers
We've added a number of other smaller language changes to help developer productivity. This includes simplified iteration over collections and arrays -- the so-called "enhanced for loop" syntax. We've added what we called boxing and unboxing to automatically map between primitive types and object types. Those are both fairly small language changes, but they simplify common tasks for developers.
As part of the ease-of-development work, we've also added support for "C" style printf. Many of us who came from a "C" background appreciate the power and simplicity of printf for simple formatting. Now you can use printf with the Java language.
Another big change is Java language annotations (JSR 175). This supports a style of declarative programming within the Java language, which started as a classic object-oriented language, full of imperative operations such as "x.doThis()" and "y.doThat()". However, as the libraries evolved, a declarative style of programming slowly crept into the platform. For example, with JavaBeans you can use particular method naming patterns, getFoo and setFoo, to define a JavaBeans "foo" property. Similarly, as part of serialization we specified that the inheritance of a particular marker interface could be used to indicate that a class was serializable. Enterprise JavaBeans also invented a variety of marker conventions to specify how EJBs work.
Now, in stepping back, we realized two things. First, a variety of these kinds of marker techniques had crept into the Java platform. Second, they were being highly effective. They were allowing developers to declaratively mark methods or classes as having a particular characteristic and then tools or libraries would perform special processing on those classes or methods. This reduced and simplified the amount of explicit programming that was necessary.
But the marker conventions we were using were rather ad hoc and were proving difficult to generalize into richer uses. So with Tiger, we've added the idea of declarative programming as a first-level concept in the Java language itself. There is now a mechanism where you can define annotation types, and then use those types to annotate classes, fields, and methods. And then tools and libraries can process those annotations and do work on the developer's behalf. This isn't just a theoretical concept. This is something we're pursuing as one of the main programming styles in J2EE 5.0, particularly in projects like EJB 3.0. This use of annotations looks like it will help considerably simplify J2EE programming.
As part of developing the releases we have treated quality as indisputably job #1. For example, we have been working to improve many of our internal engineering processes so as to more carefully manage change, to improve testing efficiency, and thus to improve overall release quality. I think this focus has been very effective.
A second major theme is performance and scalability. As part of our work on garbage collection we've tested with heaps of over 500 gigabytes of physical memory. Similarly, we've made sure that the JVM can run on extremely large multi-processor systems. (The Sun hardware guys are very kind and sometimes let us borrow some of their very biggest and shiniest toys.) Now I wouldn't necessarily recommend a 500 Gig heap or a hundred-way processor for home use quite yet. It's nice that we can scale to the very high end, but we are mostly tuning and testing on much more mundane systems.
Now, in looking at how customers actually deploy to large systems we realized we had been suffering from a flawed assumption. Historically, we've provided very detailed configuration flags to let you manually configure the JVM to best exploit server class systems. If you knew how to set the right flags, you could really boost your performance on large systems. However we've now realized that we got a little too carried away with all these configuration options and in practice many customers ignored most of these options.
So one of the things that we're introducing in Tiger is what we call performance ergonomics, where at JVM start-up the JVM will analyze the kind of environment it's in, and will now automatically configure these fancy options that you used to have to set manually. For example, if you are on a large server system with lots of memory, it will use aggressive heap options targeted for high throughput. If you want to, you can still manually configure all these options, but my advice would be to initially just try it with the defaults. This may now work even better than doing hand configuration.
The third big theme is monitoring and manageability. The goal is to make it easier for developers to see what's going on inside the JVM and inside Java applications. We've added new APIs to expose performance and management information. We're also delivering some simple monitoring and management tools as part of the J2SE 5.0 release. For example, we're including a simple JConsole tool, that lets you look at a variety of management information, including things like heap usage and the number of threads that are running.
The fourth theme is the desktop client. We've worked to improve both the performance of the Java desktop client, but also the GUI look-and-feels. We've continued to improve the quality of the Windows XP look-and-feel and the GNOME GTK look-and-feel. We've also added a new cross-platform look-and-feel called "Ocean" that provides a clean, modern, cross-platform look-and-feel.
We're also looking into the future with our GUI work and we've already starting experimenting with Tiger on some of the early Microsoft Longhorn builds. We know that the Longhorn release will be very important to desktop developers, so we're making sure that J2SE will run well and look great on Longhorn.
The fifth theme is ease of development, which we've already talked about. That includes various API updates including the printf facility I mentioned earlier. It also includes the new language features we talked about.
The sixth theme is core XML support. We've upgraded the core XML support provided in J2SE by adding new versions of the SAX parser, the DOM Document Object Model, and the XSLT transform engine.
XML and Web Services support on the Java platform continue to evolve quickly. You can get the very latest XML and web services support as part of the Java Web Services Developer Pack (JWSDP) from java.sun.com. Over time, as those ideas stabilize, we'll import them into future releases of J2SE.
The Most Important Feature of Tiger
Want to learn more about J2SE 5.0? Got a question about J2SE 5.0? Join the October 12 online chat on New Language Features in J2SE 5.0 with guests Scott Seligman, Joe Darcy, and Peter von der Ahé.
Feedback from Developers
We're also getting good feedback on release quality. We think Tiger is going to be our highest quality J2SE release ever. We're not going to be able to fix every bug, I'm afraid, but we are trying to make sure that the overall quality is high, and that this is a stable release that you can deploy on from day one.
Sun has been the overall specification lead for Tiger and has coordinated the various pieces. From within Sun, we've had several hundred people who've worked on various aspects of Tiger, either in API design, or implementation, or even more importantly in platform testing and stabilization. The latter part is the least visible but in many ways the most important part of a big release like Tiger.
So Tiger has been a very big effort, but we think the final release is well worth it!
- 相关回复 上下关系4
😅【IT新闻】Java 5.0(代号虎子)终于正式发布了
😥我说虎子怎么不见了 老兵帅客 字117 2004-09-30 15:44:22
eclipse也是可以 pdwolf 字0 2004-10-03 03:41:20
😁你们说的这个虎子已被俺物理删除.....恢复到1.1.8去也~~~~ 你克我服 字83 2004-10-01 01:38:38