Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
IwillNotQuit
Post subject: How do I run the "MyEclipse EJB 3.0 Tutorial" usin  PostPosted: Feb 12, 2010 - 05:55 PM



Joined: Feb 12, 2010
Posts: 2

I am using the "MyEclipse EJB 3.0 Tutorial" as a base; It uses the Glassfish 2 server to deploy the EJB3 and run the test-client against. When I follow this tutorial as is, it works.

I need to deploy to JBOSS 5.1.0; so I set up the JBOSS server, sucessfully deploy the EJB3 to it. BUT when I execute the test client it blows up in the ctx.lookup

javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:645)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:325)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at com.hp.les.healthMonitor.myTestClient.main(myTestClient.java:15)

Can anyone help me with this?
 
 View user's profile Send private message  
Reply with quote Back to top
support-shalini
Post subject: RE: How do I run the "MyEclipse EJB 3.0 Tutorial"  PostPosted: Feb 15, 2010 - 09:00 AM
Registered Member
Registered Member


Joined: May 18, 2009
Posts: 1532

IwillNotQuit,
Can you copy paste your installation details from MyEclipse > Installation Summary > Installation Details?
Also, please refer to the following link -
http://community.jboss.org/wiki/GetquotjavaxnamingNoInitialContextExceptionquot

_________________
Shalini
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
IwillNotQuit
Post subject: Re: RE: How do I run the "MyEclipse EJB 3.0 Tutorial&qu  PostPosted: Feb 15, 2010 - 08:33 PM



Joined: Feb 12, 2010
Posts: 2

support-shalini wrote:
IwillNotQuit,
Can you copy paste your installation details from MyEclipse > Installation Summary > Installation Details?
Also, please refer to the following link -
http://community.jboss.org/wiki/GetquotjavaxnamingNoInitialContextExceptionquot




As you requested:
*** Date:
Monday, February 15, 2010 2:09:41 PM CST

** System properties:
OS=WindowsXP
OS version=5.1.0
Java version=1.6.0_13


*** MyEclipse details:
MyEclipse Enterprise Workbench
Version: 8.0
Build id: 8.0-20091120


*** Eclipse details:
MyEclipse Enterprise Workbench

Version: 8.0
Build id: 8.0-20091120






Eclipse startup command=-os
win32
-ws
win32
-arch
x86
-showsplash
-launcher
C:\Program Files\Genuitec\MyEclipse 8.x Latest\myeclipse.exe
-name
Myeclipse
--launcher.library
C:\Program Files\Genuitec\MyEclipse 8.x Latest\../Common/plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519\eclipse_1206.dll
-startup
C:\Program Files\Genuitec\MyEclipse 8.x Latest\../Common/plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar
-install
C:/Program Files/Genuitec/MyEclipse 8.x Latest
-configuration
configuration
-clean
-vm
C:/Program Files/Genuitec/Common/binary/com.sun.java.jdk.win32.x86_1.6.0.013/jre/bin/client/jvm.dll



***** I andded the jndi.properties file as your link suggected: Stopped the server; redeployed the ejb; restarted the server; ran my client application; and this is what I get now:

javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out]
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1678)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1795)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:693)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at com.hp.les.healthClient.myTestClient.main(myTestClient.java:17)
Caused by: java.net.SocketTimeoutException: Receive timed out
at java.net.PlainDatagramSocketImpl.receive0(Native Method)
at java.net.PlainDatagramSocketImpl.receive(PlainDatagramSocketImpl.java:136)
at java.net.DatagramSocket.receive(DatagramSocket.java:712)
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1647)
... 5 more


The error still at the "ctx.lookup"
 
 View user's profile Send private message  
Reply with quote Back to top
support-shalini
Post subject: RE: Re: RE: How do I run the "MyEclipse EJB 3.0 Tutoria  PostPosted: Feb 16, 2010 - 06:20 AM
Registered Member
Registered Member


Joined: May 18, 2009
Posts: 1532

IwillNotQuit,
Can you add the context parameters in your client?
Please refer to - http://forums.sun.com/thread.jspa?threadID=5384951

Let me know if that helps.

_________________
Shalini
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits