tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lauer, Oliver" <Oliver.La...@AXA.de>
Subject AW: TC4.0 to EJB / expand TC to EJB2.0 and MDB
Date Fri, 22 Feb 2002 09:40:09 GMT
Hi all, 

I solved it, not much pretty at all, but it works. 
I couldn't influence the InitialContext of TC until now (I would like to
know how to do so :-)) so I prepared one on my own. 
With those options you can call an J2EE-RI-EJB within your "Standalone-TC":

	    java.util.Hashtable h = new java.util.Hashtable();
          h.put("java.naming.factory.url.pkgs","com.sun.enterprise.naming");
 
h.put("java.naming.factory.initial","com.sun.enterprise.naming.SerialInitCon
textFactory");

          h.put("org.omg.CORBA.ORBInitialHost","localhost");
          h.put("org.omg.CORBA.ORBInitialPort","1050");
          h.put("java.naming.provider.url","localhost:1050");
          Context initCtx             		= new InitialContext(h);
          Object  objref              		= (Object)
initCtx.lookup("ejb/clientrisession");
          J2EEClientSessionHome home  		=
(J2EEClientSessionHome)PortableRemoteObject.narrow(objref,J2EEClientSessionH
ome.class);
          J2EEClientSession j2eeClientSession	= home.create();

Oliver

> AXA eSolutions GmbH
> AXA Konzern AG Germany
> Oliver Lauer 
> Web Architect
> Wörthstraße 34
> D-50668 Köln
> Germany
> Tel.: +49 221 148 31277
> Fax: +49 221 148 43963
> Mobil: +49 179 59 064 59
> e-Mail: Oliver.Lauer@axa.de
> _____________________________
> 


-----Ursprüngliche Nachricht-----
Von: Lauer, Oliver [mailto:Oliver.Lauer@AXA.de]
Gesendet: Donnerstag, 21. Februar 2002 15:47
An: Tomcat Users List (E-Mail)
Betreff: TC4.0 to EJB


Hi, 

I try to connect to an EJB container within TC4.0. I can do so from within
an ordinary client. I can't within TC. I receive the following exception:

javax.naming.NameNotFoundException: Name ejb is not bound in this Context
	at org.apache.naming.NamingContext.lookup(NamingContext.java:811)
	at org.apache.naming.NamingContext.lookup(NamingContext.java:194)
	at
org.apache.naming.SelectorContext.lookup(SelectorContext.java:183)
	at javax.naming.InitialContext.lookup(InitialContext.java:350)
	at
org.apache.struts.action.ActionServlet.init(ActionServlet.java:504)
	at
org.apache.struts.tiles.ActionComponentServlet.init(ActionComponentServlet.j
ava:52)
	at javax.servlet.GenericServlet.init(GenericServlet.java:258)
	at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:852)
	at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:
3267)
	at
org.apache.catalina.core.StandardContext.start(StandardContext.java:3384)
	at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:785)
	at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:454)
	at
org.apache.catalina.core.StandardHost.install(StandardHost.java:712)
	at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:599)
	at org.apache.catalina.startup.HostConfig.start(HostConfig.java:777)
	at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:463)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor
t.java:155)
	at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1131)
	at
org.apache.catalina.core.StandardHost.start(StandardHost.java:612)
	at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1123)
	at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:307)
	at
org.apache.catalina.core.StandardService.start(StandardService.java:388)
	at
org.apache.catalina.core.StandardServer.start(StandardServer.java:505)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:776)
	at org.apache.catalina.startup.Catalina.execute(Catalina.java:681)
	at org.apache.catalina.startup.Catalina.process(Catalina.java:179)
	at java.lang.reflect.Method.invoke(Native Method)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243) 

I've set the the specific ORB parameters within my startup procedure: 

-Dorg.omg.CORBA.ORBInitialHost=localhost -Dorg.omg.CORBA.ORBInitialPort=1050

What do I've to do ? 

Thanks
Oliver  

> AXA eSolutions GmbH
> AXA Konzern AG Germany
> Oliver Lauer 
> Web Architect
> Wörthstraße 34
> D-50668 Köln
> Germany
> Tel.: +49 221 148 31277
> Fax: +49 221 148 43963
> Mobil: +49 179 59 064 59
> e-Mail: Oliver.Lauer@axa.de
> _____________________________
> 
> 

----------------------------------------------------------------------------
--
Aus Rechts- und Sicherheitsgruenden ist die in dieser E-Mail gegebene
Information nicht rechtsverbindlich. Eine rechtsverbindliche Bestaetigung
reichen wir Ihnen gerne auf Anforderung in schriftlicher Form nach. Beachten
Sie bitte, dass jede Form der unautorisierten Nutzung, Veroeffentlichung,
Vervielfaeltigung oder Weitergabe des Inhalts dieser E-Mail nicht gestattet
ist.Diese Nachricht  ist ausschliesslich fuer den bezeichneten Adressaten
oder dessen Vertreter bestimmt. Sollten Sie nicht der vorgesehene Adressat
dieser E-Mail oder dessen Vertreter sein, so bitten wir Sie, sich mit dem
Absender der E-Mail in Verbindung zu setzen.
----------------------------
For legal and security reasons the information provided in this e-mail is
not legally binding. Upon request we would be pleased to provide you with a
legally binding confirmation in written form. Any form of unauthorised use,
publication, reproduction, copying or disclosure of the content of this
e-mail is not permitted. This message is exclusively for the person
addressed or their representative. If you are not the intended recipient of
this message and its contents, please notify the sender immediately.

============================================================================
==


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


------------------------------------------------------------------------------
Aus Rechts- und Sicherheitsgruenden ist die in dieser E-Mail gegebene Information nicht rechtsverbindlich.
Eine rechtsverbindliche Bestaetigung reichen wir Ihnen gerne auf Anforderung in schriftlicher
Form nach. Beachten Sie bitte, dass jede Form der unautorisierten Nutzung, Veroeffentlichung,
Vervielfaeltigung oder Weitergabe des Inhalts dieser E-Mail nicht gestattet ist.Diese Nachricht
 ist ausschliesslich fuer den bezeichneten Adressaten oder dessen Vertreter bestimmt. Sollten
Sie nicht der vorgesehene Adressat dieser E-Mail oder dessen Vertreter sein, so bitten wir
Sie, sich mit dem Absender der E-Mail in Verbindung zu setzen.
----------------------------
For legal and security reasons the information provided in this e-mail is not legally binding.
Upon request we would be pleased to provide you with a legally binding confirmation in written
form. Any form of unauthorised use, publication, reproduction, copying or disclosure of the
content of this e-mail is not permitted. This message is exclusively for the person addressed
or their representative. If you are not the intended recipient of this message and its contents,
please notify the sender immediately.

==============================================================================


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


Mime
View raw message