Hi Derek,
Derek Broughton wrote:
Rob Hills wrote:
That may well work, but I suspect it's a bad habit to get into.
Creating your own Manager (extending GenericManager) and Dao (extending
GenericDao) and their implementing classes can be a bit of a chore, but
unless your app is a _very_ simple one, I think the collective wisdom
would be that following the MVC approach is worth the extra effort.
Well, $%^&*()_. An hour later I have a DAO, DAO implementation, Manager,
Manager Implementation, and I STILL get a
org.hibernate.LazyInitializationException, so I think I'm going back to the
way I had it...
Don't give up, you're almost there. You need to edit your web.xml and
uncomment the commented-out LazyLoadingFilter. Search for
LazyLoadingFilter and remove the comments from that filter. That should
fix your LazyInitializationException.
Drop the LAZY attribute in the POJO, and 30 seconds later I have my first
success of the day :-) Time for bed!
I can see the value of separating the action from the DAO, but at this stage
the extra stage of a manager & implementation isn't making any sense.
HTH,
Rob Hills
Waikiki, Western Australia