users@glassfish.java.net

Annotation/DD questions....

From: vince kraemer <Vince.Kraemer_at_Sun.COM>
Date: Thu, 22 Jun 2006 14:58:21 -0700

say I have a stateless bean like

@Stateless
public class StatelessLBean implements ejb3.StatelessLLocal {
  ...
}

and a local interface like

@Local
public interface StatelessLLocal {
 ...
}

if I wanted to change its name, would I put

<ejb-jar version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" ....>
  <enterprise-beans>
    <session>
      <ejb-name>MyNewStatelessL</ejb-name>
      <local>ejb3.StatelessLLocal</local>
      <ejb-class>ejb3.StatelessLBean</ejb-class>
      <session-type>Stateless</session-type>
    </session>
  ....

in the deployment descriptor? Or does this just create an alias for the
bean?

If I had another interface

@Local
public interface LLStatelessLLocal {
 ...
}

that I wanted to associate with the (original) bean, would I put

<ejb-jar version="3.0" xmlns="http://java.sun.com/xml/ns/javaee"....>
  <enterprise-beans>
    <session>
      <ejb-name>StatelessL</ejb-name>
      <local>ejb3.LLStatelessLLocal</local>
    </session>
  ....

or do I need to put in more info than that. bonus q: is the local
interface ejb3.StatelessLLocal still "available".

thanks,
vbk