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#4089373
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089373
Thanks, looking at the debug page shows that there are no long running conversations, although I have seen them present during exceptions. That therefore explains why none appear! However, ...
As a temporary hack I added a coupled of buttons to attempt to start and end a conversation, connected to methods annotated with @Begin and @End - under the apparently misguided notion that invoking these methods would explicitly control the conversation and hey presto something would appear.
However, I don't appear to understand conversations, any ideas?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089370#4089370
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089370
I know that can´t use @In with Entities objects. But, I need inject "Repositories" in entity class for "find" things of my Domain Model.
The designs, for example like Domain Model (DDD), says that logic and data exist in same class (Fowler/Evans). If use development with JBoss Seam, how can I construct a efficient Entity without injection (D.I.)?
-----------------------------
[]´s
Alessandro Lazarotti
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089367#4089367
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089367