1 Reply Latest reply on May 26, 2009 5:00 PM by wzkl52

    Error when looking up SLSB EJB with Spring

      Hi,

      I could deploy my application on JBoss. I am using struts, spring, toplink, ejb 2.0.

      When my application tries to looking up an EJB with spring the next error is displayed:


      Error while trying to execute Controller. Application or unexpected error has occured
      org.springframework.ejb.access.EjbAccessException: EJB instance [GranInvokerEJBLocal tateless] is not a local SLSB


      This error was present on OAS deployment previously, I needed to add the local-location attribute on orion-application.xml, How can I solve this on JBoss?

        • 1. Re: Error when looking up SLSB EJB with Spring

          This error occurs because we are trying to look up a Local interface of an stateless EJB with spring, by definition when you specify <jndi-name> on jboss.xml or ejb-jar.xml this JNDI is assigned to the remote interface. So you need to specify the local-jndi-name as follows:


          <enterprise-beans>

          <ejb-name>GranInvokerEJB</ejb-name>
          <jndi-name>GranInvokerEJB</jndi-name>
          <local-jndi-name>GranInvokerEJBLocal</local-jndi-name>

          </enterprise-beans>


          Once you do this error should be solved.

          I hope this can help you...