New Features In Java 5.0 – From Managers Point of View
The much awaited Java 5 has been launched in recent past by Sun. People who are in IT or related to IT industry were interested about its consequences on many factors. People who are developing applications using Java as a developing technology were more interested in new language features and other technological enhancements. But others for whom it is important to manage such process from higher level were more interested in things that are going to change with Java 5.
In this article we are going to discuss enhancements in Java 5 over prior versions that are important from management’s point of view.
Virtual Machine Improvements
Class Data Sharing
Class data sharing is new technique introduced to improve performance of JVM at run time. At run time of Java applications it loads system Jar file classes in a shared archive file, which are mapped with the memory. This helps JVM to improve its performance in two ways. One, loading classes at run time does not take much time, as they are already loaded in the archive, which is mapped with the memory. Also this architecture makes easy to share calluses among multiple JVMs.
So, from management’s point of view, Java applications will now run faster with Java 5 using class data sharing technique.
Improvements in Garbage Collection Algorithm
Improvements made in garbage collection algorithm and the process is aimed to make garbage collection more customizable and controlled by the application developer or the end user of any Java application. Both initial heap size and maximum heap size are increased to avoid memory crashes in large Java applications. Maximum heap size can be in GB now. The new parallel garbage collector allows user to set time limit and space-limit to read from heap size. The user or developers to avoid out-of-memory exception can increase these limits.
Thus, now architect and designer of the system has more control over garbage collection process in Java applications. They can configure it such a way that is scaled to achieve desired performance for the application.
Difference of Server Class Machine
Java community is already aware that the Java HotSpot JVM for server is developed and designed specially for server type machines to utilize special features of such machines and achieve best performance for the application. Here architects have got more control over usage of Java HotSpot JVM either server implementation or client.
At the startup of any Java application, it can be configured to use Java HotSpot server JVM to run the application if the underlying machine is detected to be a server machine. At run time it can detect if the machine is a server machine or simple desktop client. Based on configuration of the hardware and performance abilities, the application itself will choose suitable JVM for it.
Small Things
Other two significant enhancements in JVM with Java 5 are improved fatal error handling and new method added to System class named as nanoTime(). This method will provide access to nanosecond timings. But the result of this function will be dependent on operating system and hardware implementation like other date-time functions.
Changing the Mask (UI)
Java 2d is enhanced to take advantage of fonts installed on the operating system to render characters in multiple languages. The advantage of this improvement is, now there are ways to display characters of multiple languages at the same time provided supporting fonts are installed on the hosting operation system. JVM can detects fonts installed in various standard directories of operating system and load them as logical fonts.
Moreover AWT makes use of Unicode standards to display components on Windows XP and 2000 server. fonts cab are now rendered without limitations of Windows operating system.
Sound
Improvements in Java Sound technology are as listed here.
- Sound ports are now supported on all major platforms.
. - MIDI devices are supported on all major platforms.
. - The new direct audio access is implemented for all major platforms. This is optimizing to use native mixers.
. - Improved real time sequencer is implemented which supports all MIDI devices.
. - Sound characteristics of a Java application can be configurable using properties files.
. - JVM can be aborted in the middle of execution even if Java Sound is used for the application, which was not possible in prior releases.
. - MidiDevices class can query all connected Receivers and Transmitters.
Improved 2D
A number of enhancements are achieved in Java 2D with launch of Java 5. Some of them are listed here.
- Images rendered using BufferedImages are being cached now in video memory or on the server from where stream is being hosted. So now BufferedImages are also included in list of managed images by JVM and this way performance of entire application will improve.
. - Java 5 offers better control over hardware to accelerate images through hardware. The developer can now set priority of the image to be rendered on hardware. Also now GraphicsConfiguration classs allows rendering transparent images.
. - Java 5 supports OpenGL implementations for rendering of images. It support OpenGL pipeline to accelerate simple and complex images through hardware.
. - Java 2D now supports Bicubic Interpolation.
. - With Java 5 font objects can be created from file or any other stream.
Delivery Process
Delivery and Deployment enhancements are listed here those are introduced with Java 5.
- Java Web Start and Java Plug-in share common control panel now unlike prior versions where they were having separate control panels to set preferences. Changes made to common control panel apply to both.
. - Security settings now include two levels of security i.e. system level and user level security.
. - Many other deployment properties are added to security settings to allow more control over deployment security features.
. - Enterprise configuration file is introduced which can be accessed through its URL as a web resource. It allows properties having default values of locked values those can be changed at fly.
. - A new compression standard is used to compress jar (Java Archive Files) named as Pack200. Using this compression technique jars can be compression to 1/8th of original size. This helps in downloading Applets through web and also other Java applications.
. - Browser keystores will be used to authenticate security certificates of Java applications and applets. Currently this feature is supported for only Internet Explorer and Mozilla.
. - Now Java Archives can be signed with time stamps. This will help to set expiry dates of the certificate.
. - Java 5 has support for client authentication over HTTPS (here S stands for Secured; HTTPS is a web protocol derived from HTTP and offers secured transfer of data).
Tools
New standard tools being offered by Sun with the release of Java 5 to help monitor, debug, maintain and tune Java applications for developers and end users are briefly discussed in this topic.
- The newly introduced tool viz. Java Virtual Machine Tool Interface (JVMTI) is designed to provide a user interface over the Java Virtual Machine. This tool is aimed to help end users and developers to monitor resource usage, performance statistics, stages of execution, flow of execution, debugging of application and configure Java Virtual Machine settings to utilize it in optimum way. It supports advanced features like memory management, thread controls, stack frame control, monitoring of resources, memory requirements, CPU usage etc. Also there are APIs offered along with this tool so that developers of applications can add monitoring and configuration features for their application within their application or they have freedom to develop their own control panel for the application.
. - A new architecture has been introduced with Java 5 named as Java Platform Debugger Architecture.
. - The standard Java compiler, which is used widely with the command line arguments as javac is improved with new options. It can now generate class files those are compatible with Connected Limited Device Configuration. Also one programmatic interface has been added to compile classes on fly programmatically as com.sun.tools.javac .
. - Also documentation has been improved with Java 5 as it comes with command line tool named as Annotation Processing Tool (APT).
Summary
From management’s point of view, Java 5 has many things to offer including better control, improved performance, better utilization of resources, easy of development, faster development of applications, monitoring application execution etc. Also management can be interested in reporting facilities and more standard ways of developing Java applications. But being an open source technology such improvements are somewhat difficult to achieve for Java technology. But the level of flexibility it offers makes such things possible for custom tool developers using Java.
In few words, Java 5 has come with lot many improvements for management but, still we all will be looking for more in next release.