Struts2Builder is a Java code generation project. It will log into an existing database and generate a working Struts2 / Spring / Hibernate or MyBatis application for every table in that database.
Lily Code Generator can be used to generate all kinds of Java-based web code. It supports Struts2/SpringMVC, Spring 3, IBatis/Hibernate, Mysql 5 and Oracle.