-
1. Re: Unable to lookup session bean from servlet
adrian.brock Feb 26, 2003 10:48 AM (in response to anitha)This says the client closed the connection for some
reason.
Why are you sending jndi requests over JRMP?
Check for jndi.properties or any properties
you pass to the intial context that includes
provider.url
You might also try 3.0.6
Regards,
Adrian -
2. Re: Unable to lookup session bean from servlet
anitha Feb 27, 2003 5:42 AM (in response to anitha)Thanks Adrian,
I'am creating the InitialContext with the following properties in my servlet to look up a session bean.
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.provider.url=localhost:1099
java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
If i do not include provider url in my InitialContext properties i get the following exception.
(Pls Note: my JBoss installation is JBoss-3.0.0_Tomcat-4.0.3)
The Exception is :
1.javax.naming.CommunicationException: Receive timed out.
2. Root exception is java.io.InterruptedIOException: Receive timed out
at java.net.PlainDatagramSocketImpl.receive(Native Method)
at java.net.DatagramSocket.receive(DatagramSocket.java:392)
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:919)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1009)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:436)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:429)
Greatly appreciate your help
Anitha
(SE)-IIMS-New Zealand. -
3. Re: Unable to lookup session bean from servlet
anitha Feb 27, 2003 5:45 AM (in response to anitha)Thanks Adrian,
I'am creating the InitialContext with the following properties in my servlet to look up a session bean.
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.provider.url=localhost:1099
java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
If i do not include provider url in my InitialContext properties i get the following exception.
(Pls Note: my JBoss installation is JBoss-3.0.0_Tomcat-4.0.3)
The Exception is :
1.javax.naming.CommunicationException: Receive timed out.
2. Root exception is java.io.InterruptedIOException: Receive timed out
at java.net.PlainDatagramSocketImpl.receive(Native Method)
at java.net.DatagramSocket.receive(DatagramSocket.java:392)
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:919)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1009)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:436)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:429)
Greatly appreciate your help
Anitha
(SE)-IIMS-New Zealand. -
4. Re: Unable to lookup session bean from servlet
adrian.brock Feb 27, 2003 3:07 PM (in response to anitha)Use new InitialContext() with no properties.
The properties should come from a jndi.properties
which on the same server will use inVM local lookups
rather than RMI.
Your method should still work but it is way less
efficient, I don't why it is timing out?
Regards,
Adrian