Spring 3.0 Hits GA, but Don't Forget About Spring Roo RC4!
Spring Roo 1.0 RC4
If you haven't heard about Roo, it's a customizable code generation tool for quickly building Spring applications in Java. The tool was unveiled early this year and its framework uses a command line shell with context aware operations, tab completion, and coding hints. Using a standard directory format, Roo builds Java applications, integrates with popular persistence choices, and automatically generates web tiers for REST-based web UIs. Roo also auto-generates JUnit tests.
RC4 now makes extensive use of Spring 3.0's conversion APIs and has upgraded to Spring Security 3.0 RC2. Usability enhancements include TAB-base option help, filename completion, informative prompts, and more. Roo can now automatically log all commands issued in a project and all the output from Roo in response to each command. Spring Roo project lead Ben Alex gives an explanation of this feature in the Spring Roo project forums:
"File "log.roo" in the current working directory is always appended to (never overwritten). It contains all well-formed commands presented to the Roo shell and an indication of whether they worked (in which case they will not be commented out) or failed (in which case the will be prefixed by "// [failed]"). This makes the resulting logs useful for command playback."
// Spring Roo ENGINEERING BUILD [rev 452:459M] log opened at 2009-11-25 09:18:36If you're using SpringSource Tool Suite, Roo RC4 requires that you upgrade to STS 2.3.
// [failed] project --topLevelPackage com. --template ROO_ADDON_SIMPLE
project --topLevelPackage com.foo
persistence setup --provider HIBERNATE --database HYPERSONIC_IN_MEMORY
entity --name ~.Food --testAutomatically
// [failed] field boolean --fieldName from
field boolean --fieldName from --permitReservedWords
// Spring Roo ENGINEERING BUILD [rev 452:459M] log closed at 2009-11-25 09:19:48
The new Spring framework requires Java 5 or later. The updated Spring APIs bring Java 5 features, such as generics and annotations, to Spring 3.0. The framework is compatible with the final Java EE 6 specification and runtime environment thanks to the release of GlassFish v3 last week. Spring 3.0 can use JSF 2.0 and JPA 2.0 (using Eclipse 2.0) and run them outside of EE 6 in a container like Tomcat or Jetty. The Spring 3.0 framework's native REST capabilities in Spring MVC are comprehensive, but some say they're not battle tested. Spring's new expression language (SpEL) is introduced in 3.0 and it can be used to simplify the writing of rich expression. SpEL has similar syntax to the Unified EL in JSF. Spring 3.0 delivers specs like JSR-330 and JSR-303 along with new component model features into development environments with no server upgrade required. Just upgrade your Spring application libraries to Spring 3.0.