Hi,
Apologies if this has already been asked on the list, but I did a search
and couldn't find anything. I'm developing some axis 1.2.1 web services
running in a tomcat 5.5.9 server. I've written the wsdl files, and have
these specified in the wsdd files for the services. At the moment the
soap:address location for the service is specified with the IP address
of my machine for testing, as follows:
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address location="http://<IP
address>:8080/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
I've noticed that axis changes the soap:address to reflect the URL used
to request the wsdl. For example, if I call the wsdl files using, for
example, http://<IP
address>:8080/biorsws/services/BiorsAdvancedQueryDocStyle?wsdl , it is
returned as I defined it in the wsdl:
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address location="http://<IP
address>:8080/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
However, if I call the wsdl with
http://localhost:8080/biorsws/services/BiorsAdvancedQueryDocStyle?wsdl ,
the wsdl is changed to:
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address
location="http://localhost:8080/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
and if I use the name of the machine on our local network
(http://<machine
name>:8080/biorsws/services/BiorsAdvancedQueryDocStyle?wsdl) the
returned wsdl contains:
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address location="http://<machine
name>:8080/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
This happend whether I request the wsdl in a browser, using WSDL2Java,
when or using MS Visual Studio to generate a .Net client. All other
elements of the wsdl are unchanged, as far as I can see.
I'm now at the stage where I want to deploy these services on our
production server with a regular web address (http://www.gsf.de/.....)
defined for the service within the wsdl, such as
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address
location="http://www.gsf.de/ws/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
with this address mapped to the actual location of the service. However,
I'm now finding that if I request the wsdl for this service, as is
changing the address in the returned wsdl to include the machine name
and port on which the service is deployed.
<service name="BiorsAdvancedQueryDocStyleService">
<port binding="tns:BiorsAdvancedQuerySOAPBinding"
name="BiorsAdvancedQueryDocStyle">
<soap:address location="http://<machine
name>:8080/biorsws/services/BiorsAdvancedQueryDocStyle"/>
</port>
</service>
Can anyone tell me why this is happening, and more importantly, is there
a way to ensure that the wsdl returned by axis is exactly as I have
defined it.
Thanks in advance for your help.
Richard.