What’s new in Wicket 6
Wicket 6.0 is around the corner and it is time to describe what’s new and what’s has changed since Wicket 1.5. This article will mention briefly the major things. More details about the bigger changes will be provided in separate articles.
Why 6.0 ?
The Wicket team decided to use semantic versioning (http://semver.org) from now on. That means that having version like x.y.z we will fix bugs in ‘z’, introduce new features which do not break APIs in ‘y’ and break APIs in ‘x’ versions.
This new version has APIs breaks here and there (more on this below) so it must be a change in ‘x’ part of the version.
Wicket 2.0 has been used already few years ago, somewhere between Wicket 1.2 and 1.3 for a major change which didn’t work well and has been discontinued. Next option was Wicket 3.0 but since Wicket 6.0 now requires JDK 6 we decided to jump to 6.0.0. That doesn’t mean that Wicket 7 will require JDK 7.
Major changes in Wicket 6.0
ResourceReference class now can declare its dependencies so you just need to contribute a ResourceReference for your jQuery plugin for example, and the ResourceReference itself will tell Wicket that jQuery has to be delivered as well.
Additionally PackageResourceReference and its specializations can deliver minified version of their resource if such is available. For example by using
New Tree component
The previous Tree component implementation used AWT/SWING APIs and it was not possible to use it in more restricted environments like Google AppEngine. That’s why it has been deprecated and will be removed in a some next major release of Wicket.
AbstractTree and its specializations NestedTree and TableTree are the replacements.
A few new modules have been added to the Wicket portfolio. For now they are with experimental status but depending on the adoption they will either join the other modules or will be removed.
Integration with Atmosphere
The first new module is Wicket Atmosphere (Maven id: org.apache.wicket:wicket-atmosphere:jar). It is an integration with Atmosphere project and provides server push functionality. Depending on the configuration it may use WebSocket, long polling, streaming, JSONP, Server Side events mechanisms.
Wicket Native WebSocket
The second new module is again related to server push functionality but uses native integration with the underlying web container if such is supported. At the moment only Jetty 7+ and Tomcat 7+ are supported.
What didn’t make it
The task of component queueing was to remove the requirement to keep in sync the component trees in the markup and in Java. Due to various technical problems this task has been postponed and may be implemented in a later version of Wicket.
The Contexts and Dependency injection (CDI) integration implemented in wicket-cdi cannot be merged to Apache Wicket for now because it uses some libraries which are not available yet in Maven central repository. Until this problem is resolved users still can use it as described at the project site.
The Wicket team!