[wildfly-dev] How to use CNCtxFactory from WildFly

Michael Musgrove mmusgrov at redhat.com
Sun Feb 14 17:40:20 EST 2016


I am attempting to lookup a remote EJB from WildFly to WLS.

If I use COSNaming as required by [1] (by setting INITIAL_CONTEXT_FACTORY
to "com.sun.jndi.cosnaming.CNCtxFactory") I get the following error on the
WildFly end:
  "ClassNotFoundException: com.sun.jndi.cosnaming.CNCtxFactory"

If I use the default wildfly name service (new
InitialContext().lookup("corbaname:iiop:localhost:7001/NameService#SessionBean"))
I get the following error on the WLS end (presumably because I am not
using CNCtxFactory):
  "A RuntimeException was generated by the RMI server:
weblogic.corba.cos.naming.RootNamingContextImpl.resolve([Lorg.omg.CosNaming.NameComponent"

I did try adding the CosNaming dependency (<path
name="com/sun/jndi/cosnaming"/>) to
modules/system/layers/base/sun/jdk/main/module.xml or to
jboss-deployment-structure.xml in my deployment but that approach did not
work.


[1] row 3 of Table 2-1 in
https://docs.oracle.com/cd/E13222_01/wls/docs81/rmi_iiop/rmiiiop2.html

-- 
Michael Musgrove
Transactions Team
e: mmusgrov at redhat.com
t: +44 191 243 0870

Registered in England and Wales under Company Registration No. 03798903
Directors: Michael Cunningham (US), Paul Hickey (Ireland), Matt Parson
(US), Charles Peters (US)

Michael Cunningham (US), Charles Peters (US), Matt Parson (US), Michael
O'Neill(Ireland)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/wildfly-dev/attachments/20160214/98e0b9c8/attachment-0001.html 


More information about the wildfly-dev mailing list