-
1. Re: Communication between Business and Presentation Layer
grdzeli_kaci Jul 3, 2007 1:11 AM (in response to grdzeli_kaci)can anybody help me ?
-
2. Re: Communication between Business and Presentation Layer
georke2 Dec 7, 2007 9:24 AM (in response to grdzeli_kaci)Did you ever found a solution for this?
I'm looking to do something similar. We have some presentation layer (based on seam) that is integrating with an EJB3 backend. If we create one ear for that it works great. But now we would like to put the presentation layer on a separate machine and have it communicate with another EJB3 server in the backend. Question is how to split the presentation layer from the business layer? -
3. Re: Communication between Business and Presentation Layer
chawax Dec 7, 2007 9:48 AM (in response to grdzeli_kaci)I made this. But my code is generated by AndroMDA with Seam and EJB3 cartridge, so I am not sure why it works lol
But here are a few pieces of code that may help you :
The EJB is injected this way in my Seam component :@javax.ejb.EJB protected myPackage.ServiceProcessusRemote serviceProcessus;
My Seam component is itself an EJB (@javax.ejb.Stateful annotated).
And my serviceProcessus EJB is declared in ejb-jar.xml, something like this :<session> <ejb-name>ServiceProcessusBean</ejb-name> <remote>myPackage.ServiceProcessusRemote</remote> <ejb-class>myPackageServiceProcessusBean</ejb-class> <session-type>Stateless</session-type> <transaction-type>Container</transaction-type> </session>
Hope it will help you. -
4. Re: Communication between Business and Presentation Layer
pmuir Dec 9, 2007 6:46 AM (in response to grdzeli_kaci)You should be able to communicate with remote EJB3s on the business layer in the standard EJB3 way.
-
5. Re: Communication between Business and Presentation Layer
georke2 Dec 10, 2007 4:15 PM (in response to grdzeli_kaci)Thnx,
I got it working today. Two jboss instances, one containing the ejb3 business logic and one containing the web application based on seam, reusing the entities from the ejb3 layer.