客户端运行不了,急!!! magic,如果你不设置initial context的参数:javax.naming.Context.INITIAL_CONTEXT_FACTORY和javax.naming.Context.PROVIDER_URL,谁知道你要访问哪个服务器的jndi 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 我修改了代码,加上了几句 env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.cosnaming.CNCtxFactory"); env.put(Context.PROVIDER_URL, "iiop://127.0.0.1:4848"); Context initial = new InitialContext(env); Object objref= initial.lookup("java:comp/env/ejb/SimpleConverter"); ConverterHome home =(ConverterHome) PortableRemoteObject.narrow(objref, ConverterHome.class); Converter currencyConverter = home.create();错误转换成如下:javax.naming.CommunicationException: Cannot connect to ORB [Root exception is org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 208 completed: Maybe] ext.tree.panel树型菜单的字体大小如何设置? Hibernate 数据库读float类型 的数据精度问题 ksoap包放置到jb工程目录的那个文件夹下 关于spring配置事务代理模板的问题 spring 匹配所有action 实现aop编程问题 复杂的sql语句在Hibernate中如何实现? 一个如何写 JavaBean 与调用的问题,500分!绝不食言! rmi的问题 如何得到服务器变量 In Jsp(Like In Asp). 请问如何保存xml的网页 新手求救——关于DOM 请教一个Eclipse+Tomcat+Lomboz部署EJB的问题
env.put(Context.PROVIDER_URL, "iiop://127.0.0.1:4848"); Context initial = new InitialContext(env);
Object objref= initial.lookup("java:comp/env/ejb/SimpleConverter"); ConverterHome home =(ConverterHome) PortableRemoteObject.narrow(objref,
ConverterHome.class); Converter currencyConverter = home.create();错误转换成如下:javax.naming.CommunicationException: Cannot connect to ORB [Root exception is org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 208 completed: Maybe]