Is it a certificate problem?
"daniel soria" <[email protected]>
| Newsgroups | gmane.comp.java.openjms.user |
|---|---|
| Message-ID | <000501c58140$2112d6e0$0400000a@home> |
Hi everybody,
I am trying to use the jndi.properties to configure the context in the jms client.
When I use, for example:
jndihost = myjndihost
jndiport = 8443
And in my code:
Context context = new InitialContext();
Later change it for:
Hashtable properties = new Hashtable();
properties.put(Context.INITIAL_CONTEXT_FACTORY,
"org.exolab.jms.jndi.InitialContextFactory");
String host = "myjndihost";
String port = "8443";
properties.put(Context.PROVIDER_URL, "https://" + host +":" + port);
Context context = new InitialContext(properties);
in Windows XP with several virtual machines, my client tries to communicate with localhost:8443 but myjndihost isn't the localhost.
Whithout tomcat certificate in cacerts I have:
C:\Pruebas MEC II\mecclient\bin>buildmec.bat mec.net.client.Client2 -topic topic
1 -jndihost myjndihost -jndiport 8443
javax.naming.CommunicationException: Failed to get registry service for URL: htt
ps://myjndihost:8443 [Root exception is java.rmi.ConnectIOException: Failed to create
connection; nested exception is:
org.exolab.jms.net.connector.ConnectException: Failed to connect to URI=
https://myjndihost:8443/openjms-tunnel/tunnel]
at org.exolab.jms.jndi.InitialContextFactory.getInitialContext(InitialCo
ntextFactory.java:145)
With tomcat certificate in cacerts:
C:\Pruebas MEC II\mecclient\bin>buildmec.bat mec.net.client.Client2 -topic topic
1 -jndihost myjndihost -jndiport 8443
javax.naming.ServiceUnavailableException: Failed to connect to URI=https://127.0
.0.1:8443/openjms-tunnel/tunnel [Root exception is org.exolab.jms.net.connector.
ConnectException: Failed to connect to URI=https://127.0.0.1:8443/openjms-tunnel
/tunnel]
at org.exolab.jms.jndi.InitialContextFactory.getInitialContext(InitialCo
ntextFactory.java:171)
Why could this be happening?, it work fine in Linux and Windows 2000.
This connection is passing through an https tunnel.