【发布时间】:2013-10-02 10:33:28
【问题描述】:
谁能告诉我如何为 WebSphere 7 中的 EJB 3.0 无状态(本地)会话 bean 组件提供自定义 JNDI 名称?我知道服务器正在为ejblocal:<fully qualified interface name> 之类的东西提供默认名称。但我不想在我的客户端查找中使用这个名称。
我也想知道同样的方法是否也适用于 WebSphere 8.0?
【问题讨论】:
谁能告诉我如何为 WebSphere 7 中的 EJB 3.0 无状态(本地)会话 bean 组件提供自定义 JNDI 名称?我知道服务器正在为ejblocal:<fully qualified interface name> 之类的东西提供默认名称。但我不想在我的客户端查找中使用这个名称。
我也想知道同样的方法是否也适用于 WebSphere 8.0?
【问题讨论】:
interface @Remote
public interface HellowWorldBeanRemote {}
bean class import javax.ejb.Stateless;
@Stateless(mappedName="HelloWorld") //Giving custom Jndi name to ejb
public class HellowWorldBean implements HellowWorldBeanRemote {}
【讨论】: