[ http://jira.andromda.org/browse/EJB-91?page=comments#action_14970 ]
heapifyman commented on EJB-91: ------------------------------- As suggested in http://galaxy.andromda.org/forum/viewtopic.php?t=5159 I tried the following changes and they worked for me: - changed EJB Injection Definitions in "SessionBeanBase.vsl" from @javax.ejb.EJB protected ${reference.fullyQualifiedServiceRemoteInterfaceName} $stringUtils.uncapitalize(${reference.name}); to: @javax.ejb.EJB protected ${reference.fullyQualifiedInjectedServiceInterfaceName} $stringUtils.uncapitalize(${reference.name}); - added the attribute "fullyQualifiedInjectedServiceInterfaceName" (copied from fullyQualifiedServiceRemoteInterfaceName) in the "EJB3SessionFacade" in the UML model. - added the following code in "EJB3SessionFacadeLogicImpl": /** * @see org.andromda.cartridges.ejb3.metafacades.EJB3SessionFacadeLogic#handleGetFullyQualifiedInjectedServiceInterfaceName() */ protected String handleGetFullyQualifiedInjectedServiceInterfaceName() { if (this.isViewTypeLocal() || this.isViewTypeBoth()) { return this.getFullyQualifiedServiceLocalInterfaceName(); } else { return this.getFullyQualifiedServiceRemoteInterfaceName(); } } > Injection of Local Service Bean fails > ------------------------------------- > > Key: EJB-91 > URL: http://jira.andromda.org/browse/EJB-91 > Project: EJB Cartridge > Type: Bug > Environment: WinXP Pro, Java 1.5.12, Maven 2.0.5, AndroMDA 3.3-SNAPSHOT, > EJB3-cartridge 1.0-SNAPSHOT, MagicDraw 12.1 Personal Edition > Reporter: heapifyman > Assignee: Vance Karimi > > Create a Service Bean "LocalServiceBean" with "andromda.ejb.viewType = local" > and another remote Service Bean "RemoteServiceBean" in your UML model. > Then create a dependency from RemoteServiceBean to LocalServiceBean. > The generated code for injecting the LocalServiceBean is faulty because it > ignores the viewType and tries do inject a remote interface which does not > exist (see below): > @javax.ejb.EJB > protected foo.bar.LocalServiceBeanRemote localServiceBean; -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.andromda.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/