Socket Exception(redicover server) in JBoss324
pkrishnaswami Aug 15, 2004 9:28 PMI have a swing application that looks up a connection factory. This application was working fine as long as I was using Jboss304. Now I am testing this against jboss324, I get the following exception:
C:\JavaDevelopment\enterprisetechtips\Apr2003\publishing>java WeatherClient
javax.naming.CommunicationException: Receive timed out [Root exception is java.n
et.SocketTimeoutException: Receive timed out]
javax.naming.CommunicationException: Receive timed out [Root exception is java.n
et.SocketTimeoutException: Receive timed out]
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:11
17)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1225)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:514)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:507)
at javax.naming.InitialContext.lookup(InitialContext.java:347)
at SubscriptionHelper.(SubscriptionHelper.java:25)
at WeatherClient.main(WeatherClient.java:268)
Caused by: java.net.SocketTimeoutException: Receive timed out
at java.net.PlainDatagramSocketImpl.receive(Native Method)
at java.net.DatagramSocket.receive(DatagramSocket.java:711)
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:10
87)
... 6 more
Exception in thread "main" java.lang.NullPointerException
at SubscriptionHelper.(SubscriptionHelper.java:37)
at WeatherClient.main(WeatherClient.java:268)
C:\JavaDevelopment\enterprisetechtips\Apr2003\publishing>set classpath=C:\Progra
m Files\InterBase Corp\InterClient\interclient.jar;c:\j2sdk1.4.2\jre\lib\rt.jar;
c:\jython-2.1\jython.jar;;;;
I have the jndi.properties in my classpath. This file contains the following lines:
DO NOT EDIT THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING
#
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
The code that generates this excepton is as below:
try {
InitialContext ic = new InitialContext();
tcf = (TopicConnectionFactory)
ic.lookup(tcfName);
}
catch(exception ex)
{
}
the tcfname is ConnectionFactory. As I said this application worked fine against jboss304. Is there other configuration that I need to set up to get it work against jboss324.
BTW, the jboss server is running on my local machine.
Any help will be appreciated.