You need to create appropriate mappings for your entities. If you have mapped object
associations, the associations your entity requires will automagically be retrieved lazily
(or when the entity itself is retrieved if eager fetching is desired). Read up on JPA and
Hibernate for this.
Once you have accomplished this, the only place you will need to inject a DAO or your EM
is where the request for the entity occurs (likely in an SFSB). Seam also provides a Seam
Managed Persistence Context (SMPC) which allows you to achieve lazy initialization across
requests.
Good luck.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089373#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...