2 Replies Latest reply on Jan 22, 2007 10:46 AM by Pablo Javier Santa Cruz Cosp

    EJB3 interfaces questions

    Pablo Javier Santa Cruz Cosp Newbie

      Hi all,

      I have a Session Bean that looks like this:

      public @Stateless class ReverseBean implements Reverse {
       public String reverse(String s)
       String ret;
       // code to reverse the string "s" here
       return ret;

      And then, I have its corresponding interface:

      public interface Reverse {
       public String reverse(String s);

      I have five small questions:
      1) Is it OK to use only ONE class as remote AND local interface?
      2) What's the default JNDI name assigned to the Session Bean? That is, how am I suppose to do the lookup for the Session Bean in the Initial Context?
      3) Can I use @EJB injection in Servlets or injections are only available to other EJBs?
      4) Where should I specify the "client-jar" if I am using EJB3? Do I even need a "client-jar"?
      5) Where can I find more documentation about these three previous questions?

      I am using JBoss 4.0.5.GA, installed with the installer, and the original EJB3 RC9 that comes with it.