RE: OpenJms Configuration file question
"Jim Alateras" <[email protected]>
| Newsgroups | gmane.comp.java.openjms.devel |
|---|---|
| Message-ID | <[email protected]> |
We need to do this to support scenarios like 2 NICs in the same machine or
if you are using NAT.
cheers
</jima>
-----Original Message-----
From: openjms-developer-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
[mailto:openjms-developer-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org]On Behalf Of Hsieh,
Chih-Cheng
Sent: Tuesday, March 18, 2003 2:05 AM
To: openjms-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: [openjms-developer] OpenJms Configuration file question
Hi
I am using OpenJms 0.7.4. I have a client-server Java application, and I
am using OpenJms as the communication channel between them. My client
application can be run anywhere in the network. And, I start OpenJms server
in the same VM of my Server application.
Here is what I use for OpenJms configuration.
<Configuration>
<!-- Optional. This represents the default configuration -->
<ServerConfiguration host="localhost" embeddedJNDI="true"/>
<!-- Connector is TCP -->
<Connectors>
<Connector scheme="tcp">
<ConnectionFactories>
<QueueConnectionFactory
name="JmsQueueConnectionFactory"/>
<TopicConnectionFactory
name="JmsTopicConnectionFactory"/>
</ConnectionFactories>
</Connector>
</Connectors>
I found that if I used "localhost" as host inside the ServerConfiguration
tag to start my Server. My client application that is running on the
different host won't be able to connect to the JNDI service to look up the
connection factory. If I change "localhost" to the IP address of the host
where my server is running and restarts my Server. My client application
has no problem to connection to JNDI service and doing JNDI lookup.
I believe this is a bug. What I believe is that "localhost" is recorded
in the naming service when the OpenJms server is started. When the other
application tries to create initialContext and doing JNDI lookup,
"localhost" is returned as the host name from the naming service. When the
client try to connection to remote JNDI service using "localhost" as host
address, of course it won't work.
Is my assumption correct? If this is a bug, are we planning to fix it in
the future release?
Thanks,
Chih-Cheng Hsieh