This content has been marked as final.
Show 1 reply
-
1. Re: Seam Design Patterns
pmuir Feb 26, 2008 12:17 AM (in response to flsusp.fabio.dextra-sw.com)
Fábio Santos wrote on Feb 21, 2008 07:19 PM:
1) How much complexity I must put on a single stateful bean? On other words, is better to use a single stateful bean for a long running conversation or use several beans instead?I would use both designs, depending on the complexity of the conversation. Start simple, add more beans if you need them or need to factor out common functionality.
2) I become very happy when I didn't see any Java classes on my web tier (only JSF converters and validators). But, the coupling to the ejb tier becomes annoying. Is this a good practice? On other words, to use annotations like @DataModel and to put navigation specific methods on the ejb tier is a good practice?
I personally would avoid this coupling:
- Use EntityQuery and do #{myQuery.dataModel}, or do something similar with a base class of your own.
- Use navigation rules in pages.xml with rules that inspect the state of your bean, rather than logical outcomes.