[jboss-user] [JNDI/Naming/Network] - Re: javax.naming.NoInitialContextException error when access
emcwoo
do-not-reply at jboss.com
Wed Mar 14 05:36:03 EDT 2007
I have modified the classpath (by modifying the build file of the QUEUE example) to include the jar files under the following folders:
C:\Program Files\jboss-4.0.4.GA\server\default\lib
C:\Program Files\jboss-4.0.4.GA\server\messaging\lib
C:\Program Files\jboss-4.0.4.GA\client
However, the following error was encountered.
[java] javax.naming.NamingException: Failed to retrieve Naming interface [Root exception is java.io.IOException]
[java] at org.jboss.naming.HttpNamingContextFactory.getInitialContext(HttpNamingContextFactory.java:84)
[java] at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
[java] at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
[java] at javax.naming.InitialContext.init(InitialContext.java:219)
[java] at javax.naming.InitialContext.(InitialContext.java:175)
[java] at org.jboss.example.jms.common.Util.doesDestinationExist(Util.java:43)
[java] at org.jboss.example.jms.common.ExampleSupport.setup(ExampleSupport.java:146)
[java] at org.jboss.example.jms.common.ExampleSupport.run(ExampleSupport.java:57)
[java] at org.jboss.example.jms.queue.QueueExample.main(QueueExample.java:134)
[java] Caused by: java.io.IOException
[java] at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:602)
[java] at org.jboss.naming.HttpNamingContextFactory.getNamingServer(HttpNamingContextFactory.java:133)
[java] at org.jboss.naming.HttpNamingContextFactory.getInitialContext(HttpNamingContextFactory.java:80)
[java] ... 8 more
[java] Caused by: java.net.ConnectException: Connection timed out: connect
[java] at java.net.PlainSocketImpl.socketConnect(Native Method)
[java] at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
[java] at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
[java] at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
[java] at java.net.Socket.connect(Socket.java:452)
[java] at java.net.Socket.connect(Socket.java:402)
[java] at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
[java] at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
[java] at sun.net.www.http.HttpClient.openServer(HttpClient.java:618)
[java] at sun.net.www.http.HttpClient.(HttpClient.java:306)
[java] at sun.net.www.http.HttpClient.(HttpClient.java:267)
[java] at sun.net.www.http.HttpClient.New(HttpClient.java:339)
[java] at sun.net.www.http.HttpClient.New(HttpClient.java:320)
[java] at sun.net.www.http.HttpClient.New(HttpClient.java:315)
[java] at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:521)
[java] at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:498)
[java] at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:626)
[java] at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:1502)
[java] at java.net.URLConnection.getHeaderFieldInt(URLConnection.java:476)
[java] at java.net.URLConnection.getContentLength(URLConnection.java:371)
[java] at org.jboss.naming.HttpNamingContextFactory.getNamingServer(HttpNamingContextFactory.java:128)
[java] ... 9 more
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4027851#4027851
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4027851
More information about the jboss-user
mailing list