Java EE 7 was officially released yesterday with additional support for HTML5 and Web technologies, giving developers a more robust, business-focused platform for their Java applications.
The updated Java specification is the culmination of work on 14 active JSRs; chief among them was JSR 342, the umbrella specification for the platform. The main focus of Java EE 7 itself was to prepare the platform for the cloud, said Oracle.
Linda DeMichiel, specification lead for the Java EE platform and an Oracle employee, said the major themes of Java EE 7 are primarily focused on developer productivity. That means embracing popular Web technologies within the Java EE 7 stack. She highlighted the new support for JSON in Java EE 7 as an example of this focus.
Said DeMichiel: “JSON is a key technology for data transfer within HTML 5 apps. With Java EE 7, we add new APIs to enable parsing and generation of JSON.”
These new JSON capabilities go hand in hand with the new WebSocket support. The Java API for WebSocket 1.0, said DeMichiel, “enables highly efficient communication between the client and server over a single TCP connection, where the connection is held for the entire session.”
Using the WebSocket API, developers can trigger events and methods when information comes down this WebSocket connection. This, said DeMichiel, will allow developers to build reactive, asynchronous applications.
Java Server Faces was also updated in Java EE 7. DeMichiel said that previous versions of JSF couldn’t handle Web markup that it did not understand. However, in this release, which includes JSF 2.2, HTML5 can be passed through JSF directly to the browser, eliminating the potential for JSF to block new markup attributes that it hadn’t yet supported.
Elsewhere in the stack, many other mainstays of the Java EE platform were updated as well. Java Message Server (JMS) 2.0 includes a new programming model designed to make it easier for developers to use it. Additionally, a new mandatory API allows any JMS provider to be integrated with any Java EE container.
When it comes to beans, numerous changes to Java EE 7 have removed many inconsistencies between the various bean types and the Java EE Web layer. These changes allow Enterprise Java Beans 2.2 and Bean Validation 1.1 to exist in cloud-based host environments, without the potential for conflicts with JSF and the API for using REST in Java.
New in Java EE 7 is JSR 352: Batch Applications for the Java Platform. This includes a new programming model for batch applications, as well as a runtime for scheduling and executing jobs. This new support for batch operations should allow enterprises to better define their workloads for specific processing needs.
JSR 352 was accompanied by new abilities for state management. JSR 350 defines a way of offloading state into third-party providers that may have different levels of quality-of-service guarantees.
Harish Grama, vice president of WebSphere product management and development at IBM, said that Java EE 7 accomplished its goal of increasing developer productivity. “With Java EE, you truly get all the qualities of service any enterprise application would need. We’ve made it easier for programmers to consume the complex, underlying capabilities of the platform. This is key to getting a larger community to use Java EE for their application development,” he said.