[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Failed to Laizy load the Collection

2008-12-04 Thread NSchweig
Hi, I have got the same problem. In the hibernate forum they say that you have to use the opensessioninview pattern. http://www.hibernate.org/43.html If you use Spring (I do not) there ist a OpenSessionInViewFilter you can use (I think you only have to configure it in the web.xml) But I do

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Failed to Laizy load the Collection

2006-11-28 Thread efmcuiti
reubenf wrote : I think the problem is as follows: With lazy loading, objects are not loaded until referenced. Until then, references are to proxy objects. So, since all loads need to be done in the context of a session, if you load a parent object and never reference the child object until

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Failed to Laizy load the Collection

2006-11-27 Thread efmcuiti
Here is the error message that the jboss console throws: org.hibernate.lazyInitializationException: failed to lazily initialize a collection of role: org.tha.User.roles, no session or session was closed I hope you can help me View the original post :

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Failed to Laizy load the Collection

2006-11-27 Thread reubenf
I think the problem is as follows: With lazy loading, objects are not loaded until referenced. Until then, references are to proxy objects. So, since all loads need to be done in the context of a session, if you load a parent object and never reference the child object until after the session