How can I configure Hibernate in Struts?
+1
A:
There's a good JavaWorld article on this topic called Struts Recipes: Hibernate and Struts. I suggest you start there.
Bill the Lizard
2010-05-01 11:46:32
+1
A:
If you're really smart neither one will know anything about the other.
Hibernate is purely about persistence. It ought to be hidden from Struts behind an interface.
Struts is purely about view. Your Action classes ought to have references to those persistence interfaces and deal with those. It shouldn't know anything about how the interfaces are implemented.
This approach will decouple the two, making your testing job easier. You can write the persistence tier, test it thoroughly, and put it aside.
duffymo
2010-05-01 12:14:34