CORBA EJB Client
Resin 3.0

Features
Installation
Configuration
Web Applications
IOC/AOP
Resources
JSP
Quercus
Servlets and Filters
Databases
Admin (JMX)
CMP
EJB
Amber
EJB 3.0
Security
XML and XSLT
XTP
JMS
Performance
Protocols
Third-party
Troubleshooting/FAQ

Tutorials
Burlap Clients
Hessian Clients
CORBA/IIOP Server
Scrapbook

CORBA/IIOP Client
CORBA/IIOP Server
CORBA/IIOP Server
Scrapbook

CORBA (J2EE Reference Implementation)

  • Copy the client class jar and the j2ee.jar file to the WEB-INF/classes directory of your web application.
  • Add the following to your web application configuration in the resin.conf file:

    <classpath id='WEB-INF/classes/j2ee.jar'/>
    <classpath id='WEB-INF/classes/{your client class jar}'/>
    

  • In your class, explicitly create the environment for the InitialContext:

    Hashtable vEnv = new Hashtable();
    vEnv.put("org.omg.CORBA.ORBInitialHost",
             "{your server host}");
    vEnv.put("org.omg.CORBA.ORBInitialPort", 
             "{your server port}");
    vEnv.put("java.naming.factory.initial",
             "com.sun.enterprise.naming.SerialInitContextFactory");
    
    Or create a jndi-link :

    <jndi-link>
      <jndi-name>java:comp/env/ejb</jndi-name>
      <jndi-factory>com.sun.enterprise.naming.SerialInitContextFactory</jndi-factory>
      <init-param org.omg.CORBA.ORBInitialHost="{your server host}"/>
      <init-param org.omg.CORBA.ORBInitialPort="{your server port}"/>
    </jndi-link>
    

  • Make sure the InitialContext is initialised using the environment set above. Then access the bean as usual:

    InitialContext vContext = new InitialContext(vEnv);
    Object vObjRef = vContext.lookup("{your bean jndi name}");
    


CORBA/IIOP Server
CORBA/IIOP Server
Scrapbook
Copyright © 1998-2006 Caucho Technology, Inc. All rights reserved.
Resin® is a registered trademark, and HardCoretm and Quercustm are trademarks of Caucho Technology, Inc.