【发布时间】:2012-01-10 15:25:28
【问题描述】:
我试图从独立的 Java 客户端调用 EJB,得到以下错误。
查找代码
String localJNDIName = "ejbremote:gcmsnew/gcmsutilbeans.jar/CustomerSurveyManageQstBean#com.smbcgroup.gcms.utility.bl.survey.CustomerSurveyManageQstRemote";
InitialContext ic = new InitialContext();
GCMSBaseRemote bean = (GCMSBaseRemote)ic.lookup(localJNDIName);
例外
javax.naming.ConfigurationException: NamingManager.getURLContext 找不到该方案的工厂:ejbremote at com.ibm.ws.naming.jndicos.CNContextImpl.checkForUrlContext(CNContextImpl.java:471) 在 com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:160) 在 com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 在 javax.naming.InitialContext.lookup(未知来源)在 com.test.EJBClientTest.main(EJBClientTest.java:18)
环境
RAD 7.5,EJB3。 Websphere 应用服务器 7.0。
【问题讨论】: