2 Replies Latest reply on Jul 22, 2009 2:33 AM by anil3379

    Issue with LocalEJB in JBOSS

    anil3379

      I created a local EJB with
      @Stateless (mappedName="ejb/PersonSequenceEJB")
      @Remote (SequenceEJBRemote.class)
      @Local (SequenceEJBLocal.class)

      @Resource( name="jdbc/SEQDataSource",
      type=javax.sql.DataSource.class,
      mappedName="jdbc/PersonSequenceDataSource" )

      @TransactionManagement(TransactionManagementType.BEAN)
      public class SequenceEJB implements SequenceEJBRemote, SequenceEJBLocal {}

      when i look up this ejb, its giving ClassCast Exception.

      mseqLocal = (SequenceEJBLocal) init.lookup(JNDINames.EJB_SEQUENCE);


      I am suspecting that in context, there is no Local EJB it has only remote EJB. This works well in Glassfish. I want to make work with All the App server.

      with this syntax we don't have to write any <ejb-local-ref> glassfish, could you please suggest me the solution in JBOSS