I am developing a fairly simple web app using Spring MVC + JSP + Hibernate. To get started I followed this tutorial: http://www.cavalr.com/blog/Spring_3_and_Annotation_Based_Hibernate_4_Example
This is working ok, but I am concerned about the verbosity of code. To support the User entity, we also have UserDao, UserDaoImpl, UserService and UserServiceImpl. I understand that for a large enterprise application you might actually want this. But for my simple web app this is unneeded (and unwanted) complexity. I could achieve all this in Python much more simply.
So, is there any way to have Hibernate use the Active Record design pattern? The sort of thing I'd be looking to do is have User inherit methods like get() from a base class. So you could do User.get(userName)
I am open minded to using a different ORM to Hibernate; I'd just started with that as it seems the common choice. And also it's supposedly similar to Python SQLAlchemy, which I am familiar with.
I am also open minded to more out of the box solutions, perhaps an IDE plugin that can autogenerate the DAO classes.
Any suggestions appreciated!
Paul