Maksym RMA [http://community.jboss.org/people/maksrma] created the discussion
"Could not resolve @EJB reference: [EJB Reference: beanInterface..." To view the discussion, visit: http://community.jboss.org/message/624933#624933 -------------------------------------------------------------- Hello All I have problem with Stateless EJB3 dependency injection on JBoss 6.1 with ESB 4.10 . More details: I have 2 ear files. EJB and local interface in one of them, and I am trying to call this EJB in other one ear. EJB (First ear): @Stateless @Local (ProductCreditTypeDAOLocal.*class)* public class ProductCreditTypeDAOBean extends BasicDAO<ProductCreditTypeEntity, Long> implements ProductCreditTypeDAOLocal##### ..... Interface (First ear): public interface ProductCreditTypeDAOLocal .... Call (Second ear): @Stateless @Remote(EcsAdminDataDispatcher.class) public class EcsAdminDataDispatcherBean extends EcspertEJBBase implements EcsAdminDataDispatcher { @Resource private SessionContext sessionContext; @EJB private ProductCreditTypeDAOLocal productCreditTypeDAO; --- This is problem injection! I tryed enable EAR class loading isolation (jboss-app.xml): <!DOCTYPE jboss-app PUBLIC "-//JBoss//DTD J2EE Application 5.0//EN" " http://www.jboss.org/j2ee/dtd/jboss-app_5_0.dtd http://www.jboss.org/j2ee/dtd/jboss-app_5_0.dtd"> <jboss-app> <loader-repository>myapp:app=ejb3</loader-repository> -- How I understood, this one tell jboss server to load classes in isolated repository. </jboss-app> I tryed change: @Local (ProductCreditTypeDAOLocal.*clas**s)* *to @Remote but result is same (see next...).* On deploy phase next exception occurs: Error installing to Real: name=vfs:///D:/tmp/jboss-6.1.0.Final/server/efour_conf/deploy/credit/creditBL.ear state=PreReal mode=Manual requiredState=Real: org.jboss.deployers.spi.DeploymentException: Error during deploy: org.jboss.metadata.ejb.jboss.JBossEnterpriseBeanMetaData.EcsAdminDataDispatcherBean at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49) [:2.2.2.GA] .... Caused by: java.lang.RuntimeException: Could not resolve @EJB reference: [EJB Reference: beanInterface 'com.cs.creditecspert.dao.local.ProductCreditTypeDAOLocal', beanName 'null', mappedName 'null', lookupName 'null', owning unit mailto:'ComponentDeploymentContext@8065331{org.jboss.metadata.ejb.jboss.JBossEnterpriseBeanMetaData.EcsAdminDataDispatcherBean}' 'ComponentDeploymentContext@8065331{org.jboss.metadata.ejb.jboss.JBossEnterpriseBeanMetaData.EcsAdminDataDispatcherBean}'] for environment entry: env/com.cs.creditecspert.admindispatcher.EcsAdminDataDispatcherBean/productCreditTypeDAO in unit mailto:ComponentDeploymentContext@8065331{org.jboss.metadata.ejb.jboss.JBossEnterpriseBeanMetaData.EcsAdminDataDispatcherBean ComponentDeploymentContext@8065331{org.jboss.metadata.ejb.jboss.JBossEnterpriseBeanMetaData.EcsAdminDataDispatcherBean} at org.jboss.ejb3.jndi.deployers.resource.provider.AnnotatedEJBRefResourceProvider.provide(AnnotatedEJBRefResourceProvider.java:99) [:0.1.7] at org.jboss.ejb3.jndi.deployers.resource.provider.AnnotatedEJBRefResourceProvider.provide(AnnotatedEJBRefResourceProvider.java:50) [:0.1.7] As fact it works fine on jboss 4.2.3GA. Have any ideas...? I will be grateful for any.... -------------------------------------------------------------- Reply to this message by going to Community [http://community.jboss.org/message/624933#624933] Start a new discussion in JBoss Microcontainer at Community [http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2114]
_______________________________________________ jboss-user mailing list [email protected] https://lists.jboss.org/mailman/listinfo/jboss-user
