You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by José Antonio Sánchez <ge...@gmail.com> on 2007/05/18 11:04:36 UTC

[Axis2] Support for multiport services?

Hello, I'm trying to develop a service with multiple ports in Axis2
1.2. This is the wsdl part:

<wsdl:service name="Manufacturer">
    <wsdl:port name="ManufacturerB" binding="tns:ManufacturerSoapBinding">
      <soap:address
location="http://localhost:8080/axis2/services/manufacturerb"/>
    </wsdl:port>
    <wsdl:port name="ManufacturerA" binding="tns:ManufacturerSoapBinding">
      <soap:address
location="http://localhost:8080/axis2/services/manufacturera"/>
    </wsdl:port>
    <wsdl:port name="ManufacturerC" binding="tns:ManufacturerSoapBinding">
      <soap:address
location="http://localhost:8080/axis2/services/manufacturerc"/>
    </wsdl:port>
  </wsdl:service>

When I generate code I get a unique Skeleton implementation but three
different stubs, one for every port. The problem is that, once
deployed, if I access the WSDL file I get a service with three ports
and the three of them are in the same address, not in different
addresses as the original WSDL file specified. Doing so, when I use
one of the stubs to access to that service, I get an Exception because
no service is active in
http://localhost:8080/axis2/services/manufacturera, all of them are in
http://localhost:8080/axis2/services/manufacturer.
I know I can change the target address for every stub but as only one
address is active, isn't it useless to generate three different stubs
as only one address will be used?
Can I force Axis2 through the services.xml or at runtime by Java code
to have three instances of the service each of them in a different
address?

If I do multiple services instead of one service with multiple ports,
¿Can I put the same skeleton class in all three of them in the
services.xml file? ¿Do I have to replicate the code in three different
skeletons that do approximately the same?

-- 
Saludos.
José Antonio Sánchez

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org