0 Replies Latest reply on Aug 9, 2006 5:12 AM by Gabor Kiss

    If I put @PersistenceContext(unitName=

    Gabor Kiss Newbie


      I have a simple question.

      I have an EJB3.0 Session bean (RegisterUserBean). If I try to configure an EntityManager in a following way:

      protected EntityManager em;

      I can't lookup with the following:

      InitialContext ctx = new InitialContext();
      cal = (RegisterUser) ctx.lookup("RubisBeanEAR/RegisterUserBean/remote");

      becouse I get the next error msg:

      10:50:54,421 ERROR [STDERR] javax.naming.NameNotFoundException: remote not bound
      10:50:54,421 ERROR [STDERR] at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)
      10:50:54,421 ERROR [STDERR] at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)
      10:50:54,421 ERROR [STDERR] at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
      10:50:54,421 ERROR [STDERR] at org.jnp.server.NamingServer.lookup(NamingServer.java:296)
      10:50:54,421 ERROR [STDERR] at org.jnp.server.NamingServer.lookup(NamingServer.java:270)


      MySql Server 5.0

      If I don't use te annotation, ther is no error.

      Please, help me.

      Thank you very much