While still early days, and with the expert groups still having to do their job, this session discussed some of the likely advances for the Java Technology for the Web Tier we may be looking at with JEE 6. In particular the session spoke about Servlet 3.0, JSF 2.0, RESTful Web Services, Scripting and AJAX, while surprisingly enough it did not discuss JSP at all.
The major theme for JEE 6 is ‘ease of development’. Through better (options for) tool support, more configuration by exception and better default values.
The Servlet specification was hardly touched since J2EE 1.4 (2004), so some might suggest it is about time something happens. One of the possible advances could be the use of annotations to declare servlets and servlet filters. These annotations may even render the web.xml file obsolete.
We may see asynchronous support (supporting the Comet technology) on the server side:
– non blocking input/output
– delayed request handling
– delayed response close: long lived connection through which the serverc can keep pushing data to the client
In the security area Servlet 3.0 may have a login/logout facility – without requiring a full session invalidation, as well as a feature called self-registration. Servlet 3.0 will align with the changes in JSF 2.0 and on the REST API. Furthermore it will have support for such things as file upload, ordering of servlet context listeners, container wide definition of init-parameters and better welcome-file support.
Support for annotations to allow for much more declarative programming experience. Again, better default values. In so far as possible minimize or even eliminate the need for configuration files. Support for AJAX, which means changing the request processing lifecycle and enabling it to deal with partial responses for just a zone in a page rather than the entire page. Another interesting theme: make the development of JSF components easier (for example: do not require to implement as TagLibrary Handler that really could have been generated from the Component class file.
The REST (REpresentation STate) services are an alternative to the full fledged SOAP WebServices. REST services are based on the HTTP protocol with a limited set of operations (CRUD). A URL represents a resource that can be accessed by REST over HTTP with four HTTP actions (POST, GET,..). There will be an API (JSR-311) focused on develing Java Based REST WebServices. Amongst other successful REST APIs, Java will have support for the ATOM Publishing Protocol, released later this month or so.
AJAX – jMaki, Phobos, DynaFaces
The AJAX oriented DynaFaces library for JSF 1.2 adds some sort of partial page rendering support – refreshing special zonesd in the web page – to JSF. DynaFaces extends the standard JSF lifecycle. It can be used by just adding a JAR-file to the JSF 1.2 compliant application server.
Comet provides an asynchronous model based on long-lived connections between browser and web server, allowing (web)pplications to deliver data to their clients at any time. This model is based on (plain old) http 1.1.
Feeds, of which RSS feeds are the best known example, are frequently used to make an actual list of blog-entries available to RSS Feedreaders. However, the concept of a feed can be applied in a much broader sense. Any series of events really could be published as a feed. Java WebTier Technology will will implement the Atom Feed standard, soon to be specified as IETF standard. Already, there is open source project Rome, that can read and process RSS feeds. Rome and Abdera are both frameworks for consuming and producing rss-feeds.
Sun Web Developer Kit
Available for download: http://developer.sun.com/web/sdwp. Contains: free integrated toolkit, Tutorial, Resources and includes software, for example: jMaki, DynaFaces, REST. Phobos, Rome.
And where is JSP 2.x?
The topic missing from this presentation was JSP, good old Java Server Pages. No references at all to where JSP is going – so you may be wondering whether it is going anywhere at all?