This is a discussion on generate EJB Client in WSAD without moving Remote and Home Interface into the EJB Client Jar - Websphere ; Hi, I am using WSAD 5.1.2 on WEbsphere 5.1 I have an EJB project called Portal Application Service EJB . I used PortalService.java for a Stateless Session bean. I created the EJB jar from it and it had the PortalServiceHome ...
I am using WSAD 5.1.2 on WEbsphere 5.1
I have an EJB project called Portal Application Service EJB . I used PortalService.java for a Stateless Session bean. I created the EJB jar from it and it had the PortalServiceHome and PortalService object (Remote Interface)in the EJB ear.
I then created a Portal Application Service EJB Client project from the Portal Application Service EJB project.Then I regen'd the code and created the EJB jar from it. WSAD 5.1.2 now moved the PortalServiceHome and PortalService object from the EJB jar into the EJB client jar. Interesting indeed!!! Can I ensure that the Remote and Home Interface is only copied into the EJB Client Jar and not moved from the EJB jar??
Theoretically: Clients interact with the references to the remote interface.As long as the clients keep the remote interface contract, the implementation can change without the client needing to change.Sound familiar as far as our sub projects that depend on the Portal EJB Jar.So, any sub app that uses the Portal_Application_Service_EJB_Client.jar within it should not have to worry about changes done on the server side in the Portal_Application_Service_EJB.jar . The reason we have this dependency is because we have the Remote Proxy Stubs on the server side which is what Portal_Application_Service_EJB_Client.jar is-just Client Stubs or Remote Proxies.
My question is : I am not able to remove the Portal_Application_Service_EJB_Client.jar from the Portal EJB EAR in the Portal Application Service EJB Project using WSAD. Is there a way I can do that. I tried removing the dependency from the Portal Application Service EJB Project to the Portal Application Service EJB Client project but could not. Is there some gotcha that anyone knows of in WSAD which forces us to use the Portal_Application_Service_EJB_Client.jar in the EJB ear even though we do need need it theoretically or am I missing some setting in WSAD ? I hope it is the latter because that might resolve the dependency issue for sub-apps that we use and which have to change otherwise each time we change the serverside EJB.
Is there is an easier way out in WSAD rather than trying with some ant task. I have seen examples that Websphere provides for EJB ears which do not have the EJB Client jar in it but have only the EJB jar in it.
How can I create a EJB client JAR which does not remove the Remote and Home Interface from the EJB jar into the EJB Client jar ?